public String createProxyDestination()
{
String serviceId = "proxy-service";
String id = "RC_WeatherService";
HTTPProxyService proxyService = (HTTPProxyService)msgBroker.getService(serviceId);
HTTPProxyDestination proxyDest = new HTTPProxyDestination();
proxyDest.setId(id);
proxyDest.setManaged(true);
proxyDest.setService(proxyService);
// we'll use the default channel - so nothing else is needed
// we'll use the default adapter - so nothing else is needed
// set destination properties
proxyDest.setDefaultUrl("http://{server.name}:{server.port}/{context.root}/services/WeatherService?wsdl");
proxyDest.addDynamicUrl("http://{server.name}:*/{context.root}/services/WeatherService");
proxyService.addDestination(proxyDest);
if (proxyService.isStarted())
proxyDest.start();
return "Destination: "+id+" created for Service: "+serviceId;
}