use of org.apache.ode.bpel.epr.WSDL11Endpoint in project carbon-business-process by wso2.
the class PeopleActivity method getUnifiedEndpoint.
public UnifiedEndpoint getUnifiedEndpoint() throws FaultException {
int tenantId = B4PServiceComponent.getBPELServer().getMultiTenantProcessStore().getTenantId(processId);
ProcessConfigurationImpl processConf = (ProcessConfigurationImpl) B4PServiceComponent.getBPELServer().getMultiTenantProcessStore().getTenantsProcessStore(tenantId).getProcessConfiguration(processId);
EndpointConfiguration epConf = processConf.getEndpointConfiguration(new WSDL11Endpoint(serviceName, servicePort));
try {
return epConf.getUnifiedEndpoint();
} catch (AxisFault axisFault) {
throw new FaultException(BPEL4PeopleConstants.B4P_FAULT, "Error occurred while reading UnifiedEndpoint for service " + serviceName, axisFault);
}
}
use of org.apache.ode.bpel.epr.WSDL11Endpoint in project carbon-business-process by wso2.
the class BPELBindingContextImpl method publishAxisService.
private BPELProcessProxy publishAxisService(ProcessConf processConfiguration, QName serviceName, String portName) throws AxisFault {
// TODO: Need to fix this to suite multi-tenant environment
// TODO: There is a problem in this, in this manner we can't have two axis services with
// same QName
BPELProcessProxy processProxy = new BPELProcessProxy(processConfiguration, bpelServer, serviceName, portName);
ConfigurationContext tenantConfigCtx = getConfigurationContextFromProcessConfiguration(processConfiguration);
AxisService axisService;
try {
axisService = AxisServiceUtils.createAxisService(tenantConfigCtx.getAxisConfiguration(), processProxy);
EndpointConfiguration endpointConfig = ((ProcessConfigurationImpl) processConfiguration).getEndpointConfiguration(new WSDL11Endpoint(serviceName, portName));
ServiceConfigurationUtil.configureService(axisService, endpointConfig, tenantConfigCtx);
} catch (AxisFault e) {
log.error("Error occurred creating the axis service " + serviceName.toString());
throw new DeploymentException("BPEL Package deployment failed.", e);
}
processProxy.setAxisService(axisService);
removeBPELProcessProxyAndAxisService(processConfiguration.getDeployer(), serviceName, portName);
services.put(processConfiguration.getDeployer(), serviceName, portName, processProxy);
ArrayList<AxisService> serviceList = new ArrayList<AxisService>();
serviceList.add(axisService);
DeploymentEngine.addServiceGroup(createServiceGroupForService(axisService), serviceList, null, null, tenantConfigCtx.getAxisConfiguration());
//
if (log.isDebugEnabled()) {
log.debug("BPELProcessProxy created for process " + processConfiguration.getProcessId());
log.debug("AxisService " + serviceName + " created for BPEL process " + processConfiguration.getProcessId());
}
return processProxy;
}
use of org.apache.ode.bpel.epr.WSDL11Endpoint in project carbon-business-process by wso2.
the class PartnerService method initUEP.
private void initUEP() throws AxisFault {
EndpointConfiguration endpointConf = ((ProcessConfigurationImpl) processConfiguration).getEndpointConfiguration(new WSDL11Endpoint(this.serviceName, portName));
if (endpointConf == null) {
uep = new UnifiedEndpoint();
uep.setUepId(this.serviceName.getLocalPart());
uep.setAddressingEnabled(true);
uep.setAddressingVersion(UnifiedEndpointConstants.ADDRESSING_VERSION_FINAL);
} else {
uep = endpointConf.getUnifiedEndpoint();
}
}
Aggregations