public void create ( String fqn , boolean ephemeral ) { awaitRunning ( ) ; try { LOG . trace ( "Creating {} {}" , fqn , ephemeral ? "(ephemeral)" : "" ) ; channel . send ( new Message ( null , new Request ( Request . CREATE , fqn , ephemeral ) ) ) ; synchronized ( updateCondition ) { while ( ! exists ( fqn ) ) updateCondition . wait ( ) ; } } catch ( Exception ex ) { LOG . error ( "failure bcasting PUT request" , ex ) ; } }
Adds a new node to the tree . If the node does not exist yet it will be created . Also parent nodes will be created if non - existent . If the node already exists this is a no - op it s status as ephemeral may change .