code: public Future enqueue(final QueryExecutionEvent event) {
          if (!paused) {
              return worker.submit(new Runnable() {
                  @Override public void run() {
                      QueryStats queryStats = statsByQuery.get(event.getQuery());
                      if (queryStats == null) {
                          statsByQuery.put(event.getQuery(), queryStats = new QueryStats(event.getQuery()));
                      }
                      queryStats.addQueryTime(event.getTime());
                  }
              });
          }else{
              return null;
          }
      }
docs: Enqueues a query execution event for processing.
  
  @param event instance of event.
  @return instance of Future associated with processing of event. You can examine that object
  to see if this event was processed.  In case the queue is paused, an event is not processed,
  and return value is <code>null</code>.