public EJBClientClusterNodeConfig(final EJBClientDescriptorMetaData.ClusterNodeConfig clusterNodeConfig, final ClassLoader deploymentClassLoader, final ServiceRegistry serviceRegistry) {
this.delegate = clusterNodeConfig;
this.setConnectionTimeout(clusterNodeConfig.getConnectTimeout());
final Properties channelProps = clusterNodeConfig.getChannelCreationOptions();
if (channelProps != null) {
final OptionMap channelOpts = getOptionMapFromProperties(channelProps, this.getClass().getClassLoader());
logger.debug("Channel creation options for node " + clusterNodeConfig.getNodeName() + " are " + channelOpts);
this.setChannelCreationOptions(channelOpts);
}
final Properties connectionProps = clusterNodeConfig.getConnectionOptions();
if (connectionProps != null) {
final OptionMap connectOpts = getOptionMapFromProperties(connectionProps, this.getClass().getClassLoader());
logger.debug("Connection creation options for node " + clusterNodeConfig.getNodeName() + " are " + connectOpts);
this.setConnectionCreationOptions(connectOpts);
}
this.setCallbackHandler(serviceRegistry, clusterNodeConfig.getUserName(), clusterNodeConfig.getSecurityRealm());
}