code: public void retainNode(String id) {
          synchronized (retainedNodes) {
              Node current = getCurrentNode();
  
              if (current != null) {
                  retainedNodes.put(id, current);
              }
          }
      }
docs: This method indicates that the current node, for this thread of execution, should
  be retained temporarily pending further changes.
  
  @param id The identifier used to later on to identify the node