code: @Override
    public void release(T resource) {
      if (resource != null) {
        mResources.add(resource);
        try (LockResource r = new LockResource(mTakeLock)) {
          mNotEmpty.signal();
        }
      }
    }
docs: Releases an object of type T, this must be called after the thread is done using a resource
  obtained by acquire.
  
  @param resource the resource to be released, it should not be reused after calling this method