private void deployModule ( final Node node , final InstanceContext instance , final CountingCompletionHandler < Void > counter ) { log . debug ( String . format ( "%s - Deploying %s to %s" , NetworkManager . this , instance . component ( ) . asModule ( ) . module ( ) , node . address ( ) ) ) ; node . deployModule ( instance . component ( ) . asModule ( ) . module ( ) , Components . buildConfig ( instance , cluster ) , 1 , new Handler < AsyncResult < String > > ( ) { @ Override public void handle ( AsyncResult < String > result ) { if ( result . failed ( ) ) { counter . fail ( result . cause ( ) ) ; } else { deploymentIDs . put ( instance . address ( ) , result . result ( ) , new Handler < AsyncResult < String > > ( ) { @ Override public void handle ( AsyncResult < String > result ) { counter . succeed ( ) ; } } ) ; } } } ) ; }
Deploys a module component instance in the network s cluster .