code: public void mark() {
          final long currentTimeMillis = clock.currentTimeMillis();
  
          synchronized (queue) {
              if (queue.size() == capacity) {
                  /*
                   * we're all filled up already, let's dequeue the oldest
                   * timestamp to make room for this new one.
                   */
                  queue.removeFirst();
              }
              queue.addLast(currentTimeMillis);
          }
      }
docs: Record a new event.