code: public void addWorkerHook(IWorkerHook workerHook) {
          if(null == workerHook) {
              throw new IllegalArgumentException("WorkerHook must not be null.");
          }
  
          _workerHooks.add(ByteBuffer.wrap(Utils.javaSerialize(workerHook)));
      }
docs: Add a new worker lifecycle hook
  
  @param workerHook the lifecycle hook to add