accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Josh Elser (JIRA)" <>
Subject [jira] [Commented] (ACCUMULO-3840) Refactor OpTimer so that it does not use log4j logger.
Date Fri, 22 May 2015 18:00:18 GMT


Josh Elser commented on ACCUMULO-3840:

Thanks for putting up a patch, Ed.

private static enum Timers {

This ends up duplicated all over the place. The only place I see the enum being used well
is in BulkImporter, where it actually does result in a nice simplification. Maybe it would
make sense to consolidate the following case in a class that extends our StopWatch to simplify
client code.

public class SingleStopWatch extends StopWatch<Timers> {
  private static enum Timers {

  public void synchronized start() {

  public void synchronized stop() {

I'd love to be working towards have the client API instrumented well so that it's really clear
to just look at a client application and know what took long on the client (complements the
recent HTrace work on the server -- we can hopefully get to a full picture of client+server

I have some other irritations about our StopWatch class (synchronization should be removed
and mark the class as not threadsafe, should try to avoid System.currentTimeMillis), but those
don't need to be addressed now.


> Refactor OpTimer so that it does not use log4j logger.
> ------------------------------------------------------
>                 Key: ACCUMULO-3840
>                 URL:
>             Project: Accumulo
>          Issue Type: Sub-task
>          Components: build
>    Affects Versions: 1.6.2, 1.7.0
>            Reporter: Ed Coleman
>            Assignee: Ed Coleman
>            Priority: Minor
>             Fix For: 1.8.0
>         Attachments: ACCUMULO-3840.patch
> OpTimer currently uses log4j specific classes. OpTimer and the callers can be modified
so that log4j dependencies are not required.
> The evaluation of timer consolidation raised in ACCUMULO-3329 can still be performed.

This message was sent by Atlassian JIRA

View raw message