protected boolean createProxy ( Neighbour neighbour , DestinationHandler destination , MESubscription subscription , SIBUuid12 topicSpace , String topic , boolean warmRestarted ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createProxy" , new Object [ ] { neighbour , destination , subscription , topicSpace , topic , new Boolean ( warmRestarted ) } ) ; boolean outputHandlerCreated = false ; // Assign this Handler to the MatchSpace (as long as the topic space // exists, otherwise the proxy is in limbo until either D3 catches up // with the topic space declaration, or the proxy is deleted. if ( destination != null ) { // Get the PubSubHandler from the destination object. PubSubOutputHandler handler = destination . getPubSubOutputHandler ( neighbour . getUUID ( ) ) ; // If there isn't an OutputHandler, then create one. if ( handler == null ) { handler = destination . createPubSubOutputHandler ( neighbour ) ; } // Set the forign topicspace mapping handler . setTopicSpaceMapping ( subscription . getForeignTSName ( ) ) ; // Set the topic in the output handler. handler . addTopic ( topic ) ; // Set the information needed for the commit subscription . registerForPostCommit ( _proxyHandler , destination , handler , neighbour ) ; outputHandlerCreated = true ; } else { // Add a reference into the Neighbours class to indicate that we // have a Proxy subscription, but no destination to add it to, so // we will wait until this destination is created before adding it. addTopicSpaceReference ( neighbour . getUUID ( ) , topicSpace , topic , warmRestarted ) ; subscription . registerForPostCommit ( neighbour , this ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createProxy" , new Boolean ( outputHandlerCreated ) ) ; return outputHandlerCreated ; }
Creates the proxy based on the meName topicSpace and topic for the originating ME .