public static String getStaticNodeId ( String nodeId ) { String application = NodeIdBean . parse ( nodeId ) . getApplication ( ) ; if ( nodeId_to_StaticFinalId_map . get ( nodeId ) == null ) { Instance < NodeStatus > instance = ApplicationDiscovery . singleton . instance ( nodeId ) ; if ( instance != null ) { LOG . debug ( "Instance with given nodeId is found online, then initialize its static node id and put it into the map." ) ; onEvent ( nodeId ) ; } else { LOG . warn ( new IllegalArgumentException ( "Bad node id or the node is offline: " + nodeId ) ) ; } } return nodeId_to_StaticFinalId_map . get ( nodeId ) == null ? application + NodeIdBean . splitter + "null" : //it represents a none exited static id. application + NodeIdBean . splitter + nodeId_to_StaticFinalId_map . get ( nodeId ) ; }
Lasy - create staticNodeId for the given node id .