public void setAxisService(AxisService axisService) { this.axisService = axisService; if (this.axisService != null) { this.axisServiceGroup = axisService.getAxisServiceGroup(); } else { this.axisServiceGroup = null; } }
public void setAxisService(AxisService axisService) { this.axisService = axisService; if (this.axisService != null) { this.axisServiceGroup = axisService.getAxisServiceGroup(); } else { this.axisServiceGroup = null; } }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
private String getRegistryServicePath(AxisService service) { StringBuilder pathValue = new StringBuilder(); return (pathValue .append(RegistryResources.SERVICE_GROUPS) .append(service.getAxisServiceGroup().getServiceGroupName()) .append(RegistryResources.SERVICES) .append(service.getName())).toString(); }
/** * Remove a service. * * @param name name of service to remove * @throws AxisFault */ public synchronized void removeService(String name) throws AxisFault { AxisService service = removeServiceReferences(name); if (service != null) { AxisServiceGroup serviceGroup = service.getAxisServiceGroup(); serviceGroup.removeService(name); log.debug(Messages.getMessage("serviceremoved", name)); } }
/** * Remove a service. * * @param name name of service to remove * @throws AxisFault */ public synchronized void removeService(String name) throws AxisFault { AxisService service = removeServiceReferences(name); if (service != null) { AxisServiceGroup serviceGroup = service.getAxisServiceGroup(); serviceGroup.removeService(name); log.debug(Messages.getMessage("serviceremoved", name)); } }
/** * Deploy a service to the embedded AxisConfiguration, and initialize it. * * @param service service to deploy * @throws AxisFault if there's a problem */ public void deployService(AxisService service) throws AxisFault { axisConfiguration.addService(service); if (Constants.SCOPE_APPLICATION.equals(service.getScope())) { ServiceGroupContext sgc = createServiceGroupContext(service.getAxisServiceGroup()); DependencyManager.initService(sgc); } }
/** * Deploy a service to the embedded AxisConfiguration, and initialize it. * * @param service service to deploy * @throws AxisFault if there's a problem */ public void deployService(AxisService service) throws AxisFault { axisConfiguration.addService(service); if (Constants.SCOPE_APPLICATION.equals(service.getScope())) { ServiceGroupContext sgc = createServiceGroupContext(service.getAxisServiceGroup()); DependencyManager.initService(sgc); } }
/** * Release the AxisService objects associated with this EndpointDescription. Note that * this should only be called by the ServiceDescription that owns this EndpointDescrition. * * @param configurationContext The Axis2 ConfigurationContext holding the AxisConfiguration * from which the AxisServices should be removed. */ void releaseResources(ConfigurationContext configurationContext) { if (configurationContext != null) { AxisConfiguration axisConfig = configurationContext.getAxisConfiguration(); AxisService axisService = getAxisService(); AxisServiceGroup axisServiceGroup = axisService.getAxisServiceGroup(); try { axisConfig.removeServiceGroup(axisServiceGroup.getServiceGroupName()); } catch (AxisFault e) { if (log.isDebugEnabled()) { log.debug("EndpointDescriptionImpl release resources caught exception which it is ignoring", e); } } } } }
private static ServiceContext fillServiceContextAndServiceGroupContext(AxisService axisService, ConfigurationContext configurationContext) throws AxisFault { String serviceGroupContextId = UIDGenerator.generateURNString(); ServiceGroupContext serviceGroupContext = configurationContext.createServiceGroupContext(axisService.getAxisServiceGroup()); serviceGroupContext.setId(serviceGroupContextId); configurationContext.addServiceGroupContextIntoSoapSessionTable(serviceGroupContext); return serviceGroupContext.getServiceContext(axisService); }
private static ServiceContext fillServiceContextAndServiceGroupContext(AxisService axisService, ConfigurationContext configurationContext) throws AxisFault { String serviceGroupContextId = UIDGenerator.generateURNString(); ServiceGroupContext serviceGroupContext = configurationContext.createServiceGroupContext(axisService.getAxisServiceGroup()); serviceGroupContext.setId(serviceGroupContextId); configurationContext.addServiceGroupContextIntoSoapSessionTable(serviceGroupContext); return serviceGroupContext.getServiceContext(axisService); }
/** * Configure the ServiceClient to interact with the Web service described by the specified * AxisService object. * * @param axisService the AxisService that represents the new Web service. * @throws AxisFault if an error occurs while configuring the ServiceClient. */ public void setAxisService(AxisService axisService) throws AxisFault { if (axisService == null) { // AxisFault? throw new IllegalArgumentException("AxisService is null"); } synchronized (this.axisConfig) { axisConfig.removeService(this.axisService.getName()); this.axisService = axisService; axisService.setClientSide(true); axisConfig.addService(axisService); } AxisServiceGroup axisServiceGroup = axisService.getAxisServiceGroup(); ServiceGroupContext serviceGroupContext = configContext.createServiceGroupContext(axisServiceGroup); this.serviceContext = serviceGroupContext.getServiceContext(axisService); }
/** * Clean up configuration created with this client. Call this method when you're done using the * client, in order to discard any associated resources. * * @throws AxisFault in case of error */ public void cleanup() throws AxisFault { // if a configuration context was created for this client there'll also // be a service group, so discard that if (!createConfigCtx) { String serviceGroupName = axisService.getAxisServiceGroup().getServiceGroupName(); AxisConfiguration axisConfiguration = configContext.getAxisConfiguration(); AxisServiceGroup asg = axisConfiguration.getServiceGroup(serviceGroupName); if ((asg != null) && removeAxisService) { axisConfiguration.removeServiceGroup(serviceGroupName); } } else { configContext.terminate(); } }
private void createAndFillContexts(AxisService service, MessageContext msgContext, SessionContext sessionContext) throws AxisFault { ServiceGroupContext serviceGroupContext; AxisServiceGroup axisServiceGroup = service.getAxisServiceGroup(); ConfigurationContext configCtx = msgContext.getConfigurationContext(); serviceGroupContext = configCtx.createServiceGroupContext(axisServiceGroup); msgContext.setServiceGroupContext(serviceGroupContext); ServiceContext serviceContext = serviceGroupContext.getServiceContext(service); msgContext.setServiceContext(serviceContext); if (sessionContext != null) { sessionContext.addServiceContext(serviceContext); sessionContext.addServiceGroupContext(serviceGroupContext); } }
private void createAndFillContexts(AxisService service, MessageContext msgContext, SessionContext sessionContext) throws AxisFault { ServiceGroupContext serviceGroupContext; AxisServiceGroup axisServiceGroup = service.getAxisServiceGroup(); ConfigurationContext configCtx = msgContext.getConfigurationContext(); serviceGroupContext = configCtx.createServiceGroupContext(axisServiceGroup); msgContext.setServiceGroupContext(serviceGroupContext); ServiceContext serviceContext = serviceGroupContext.getServiceContext(service); msgContext.setServiceContext(serviceContext); if (sessionContext != null) { sessionContext.addServiceContext(serviceContext); sessionContext.addServiceGroupContext(serviceGroupContext); } }
private AxisDescription getUpperLevel(short type, AxisDescription thisLevel) { switch (type) { case AXIS_BINDING_MESSAGE: return ((AxisBindingMessage) thisLevel).getAxisBindingOperation(); case AXIS_BINDING_OPERATION: return ((AxisBindingOperation) thisLevel).getAxisBinding(); case AXIS_BINDING: return ((AxisBinding) thisLevel).getAxisEndpoint(); case AXIS_ENDPOINT: return ((AxisEndpoint) thisLevel).getAxisService(); case AXIS_MESSAGE: return ((AxisMessage) thisLevel).getAxisOperation(); case AXIS_OPERATION: return ((AxisOperation) thisLevel).getAxisService(); case AXIS_SERVICE: return ((AxisService) thisLevel).getAxisServiceGroup(); case AXIS_SERVICE_GROUP: return ((AxisServiceGroup) thisLevel).getAxisConfiguration(); default: return null; } }