AddressEndpoint endpoint = new AddressEndpoint();
endpoint.setEnableMBeanStats(false);
endpoint.setName("DLB:" + member.getHostName() +
":" + member.getPort() + ":" + UUID.randomUUID());
EndpointDefinition definition = new EndpointDefinition();
definition.setTimeoutAction(SynapseConstants.DISCARD_AND_FAULT);
definition.setTimeoutDuration(LoadBalancerConfiguration.getInstance().getEndpointTimeout());
definition.setReplicationDisabled(true);
definition.setAddress(to.getAddress());
endpoint.setDefinition(definition);
endpoint.init((SynapseEnvironment)
((Axis2MessageContext) synCtx).getAxis2MessageContext().
getConfigurationContext().getAxisConfiguration().