[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #19614 [Metrics/Metrics website]: metrics-web should confirm to style guide



#19614: metrics-web should confirm to style guide
-------------------------------------+-------------------------------
 Reporter:  iwakeh                   |          Owner:  karsten
     Type:  task                     |         Status:  merge_ready
 Priority:  Medium                   |      Milestone:  Metrics 1.0.0
Component:  Metrics/Metrics website  |        Version:
 Severity:  Normal                   |     Resolution:
 Keywords:                           |  Actual Points:
Parent ID:  #19611                   |         Points:
 Reviewer:                           |        Sponsor:
-------------------------------------+-------------------------------
Changes (by iwakeh):

 * status:  needs_review => merge_ready


Comment:

 That was a lot of work here.  And, good to add a general checkstyle task.

 The restructuring of the project will be at leas one more ticket.  I added
 it to the [https://trac.torproject.org/projects/tor/wiki/doc/metrics-
 web/Improvements#DesignImprovements development page].

 Ready for merge.

 One more suppression could go away:

 {{{
 diff --git
 a/modules/legacy/src/org/torproject/ernie/cron/performance/TorperfProcessor.java
 b/modules/legacy/src/org/torproject/ernie/cron/performance/TorperfProcessor.java
 index 751e7b9..87cbf90 100644
 ---
 a/modules/legacy/src/org/torproject/ernie/cron/performance/TorperfProcessor.java
 +++
 b/modules/legacy/src/org/torproject/ernie/cron/performance/TorperfProcessor.java
 @@ -27,7 +27,7 @@ import java.util.TreeMap;
  import java.util.logging.Level;
  import java.util.logging.Logger;

 -@SuppressWarnings("checkstyle:variabledeclarationusagedistance")
 +
  public class TorperfProcessor {

    /** Processes Torperf data from the given directory and writes
 @@ -224,13 +224,13 @@ public class TorperfProcessor {
            String allDateSizeSource = e.getKey();
            dlTimes = e.getValue();
            Collections.sort(dlTimes);
 -          long q1 = dlTimes.get(dlTimes.size() / 4 - 1);
 -          long md = dlTimes.get(dlTimes.size() / 2 - 1);
 -          long q3 = dlTimes.get(dlTimes.size() * 3 / 4 - 1);
            long[] status = statusesAllSources.get(allDateSizeSource);
            timeouts = status[0];
            failures = status[1];
            requests = status[2];
 +          long q1 = dlTimes.get(dlTimes.size() / 4 - 1);
 +          long md = dlTimes.get(dlTimes.size() / 2 - 1);
 +          long q3 = dlTimes.get(dlTimes.size() * 3 / 4 - 1);
            stats.put(allDateSizeSource,
                String.format("%s,%s,%s,%s,%s,%s,%s",
                allDateSizeSource, q1, md, q3, timeouts, failures,
 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/19614#comment:7>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs