/** * Stop the proxy service * @param synCfg the synapse configuration */ public void stop(SynapseConfiguration synCfg) { AxisConfiguration axisConfig = synCfg.getAxisConfiguration(); if (axisConfig != null) { AxisService as = axisConfig.getServiceForActivation(this.getName()); //If an active AxisService is found if (as != null) { if (as.isActive()) { as.setActive(false); } axisConfig.notifyObservers(new AxisEvent(AxisEvent.SERVICE_STOP, as), as); } this.setRunning(false); auditInfo("Stopped the proxy service : " + name); } else { auditWarn("Unable to stop proxy service : " + name + ". Couldn't access Axis configuration"); } }
auditInfo("Building Axis service for Proxy service : " + name); AxisService proxyService = null; SynapseConstants.SERVICE_TYPE_PARAM_NAME, SynapseConstants.PROXY_SERVICE_TYPE); if (serviceGroup == null) { auditInfo("Adding service " + name + " to the Axis2 configuration"); axisCfg.addService(proxyService); } else { auditInfo("Adding service " + name + " to the service group " + serviceGroup); if (axisCfg.getServiceGroup(serviceGroup) == null) { auditInfo("WS-Addressing is enabled for service : " + name); try { proxyService.engageModule(axisCfg.getModule( auditInfo("WS-Security is enabled for service : " + name); try { proxyService.engageModule(axisCfg.getModule( wsdlPublished = wsdlFound; auditInfo("Successfully created the Axis2 service for Proxy service : " + name); return proxyService;
auditInfo("Building Axis service for Proxy service : " + name); SynapseConstants.SERVICE_TYPE_PARAM_NAME, SynapseConstants.PROXY_SERVICE_TYPE); if (serviceGroup == null) { auditInfo("Adding service " + name + " to the Axis2 configuration"); axisCfg.addService(axisService); } else { auditInfo("Adding service " + name + " to the service group " + serviceGroup); if (axisCfg.getServiceGroup(serviceGroup) == null) { auditInfo("WS-Addressing is enabled for service : " + name); try { axisService.engageModule(axisCfg.getModule( auditInfo("WS-Security is enabled for service : " + name); try { axisService.engageModule(axisCfg.getModule( auditInfo("Successfully created the Axis2 service for Proxy service : " + name); return axisService;
/** * Stop the proxy service * @param synCfg the synapse configuration */ public void stop(SynapseConfiguration synCfg) { AxisConfiguration axisConfig = synCfg.getAxisConfiguration(); if (axisConfig != null) { if (targetInLineInSequence != null) { targetInLineInSequence.destroy(); } if (targetInLineOutSequence != null) { targetInLineOutSequence.destroy(); } if (targetInLineFaultSequence != null) { targetInLineFaultSequence.destroy(); } AxisService as = axisConfig.getServiceForActivation(this.getName()); if (as != null && as.isActive()) { as.setActive(false); axisConfig.notifyObservers(new AxisEvent(AxisEvent.SERVICE_STOP, as), as); } this.setRunning(false); auditInfo("Stopped the proxy service : " + name); } else { auditWarn("Unable to stop proxy service : " + name + ". Couldn't access Axis configuration"); } }
axisConfig.notifyObservers(new AxisEvent(AxisEvent.SERVICE_START, as), as); this.setRunning(true); auditInfo("Started the proxy service : " + name); } else { auditWarn("Unable to start proxy service : " + name +
axisConfig.notifyObservers(new AxisEvent(AxisEvent.SERVICE_START, as), as); this.setRunning(true); auditInfo("Started the proxy service : " + name); } else { auditWarn("Unable to start proxy service : " + name + ". Couldn't access Axis configuration");