code: public void clear() {
          // The alternative is to iterate through the keys and call #remove(),
          // which
          // adds unnecessary contention on the eviction lock and buffers.
          evictionLock.lock();
          try {
              Node node;
              while ((node = evictionDeque.poll()) != null) {
                  data.remove(node.key, node);
                  node.makeDead();
              }
  
              // Drain the buffers and run only the write tasks
              for (int i = 0; i < buffers.length; i++) {
                  Queue<Task> buffer = buffers[i];
                  int removed = 0;
                  Task task;
                  while ((task = buffer.poll()) != null) {
                      if (task.isWrite()) {
                          task.run();
                      }
                      removed++;
                  }
                  bufferLengths.addAndGet(i, -removed);
              }
          } finally {
              evictionLock.unlock();
          }
      }
docs: /* ---------------- Concurrent Map Support --------------