use of com.arjuna.webservices11.ServiceRegistry in project narayana by jbosstm.
the class BAInteropUtil method getParticipantCompletionParticipant.
/**
* Get the endpoint reference for a participant completion participant.
* @param id The participant id.
* @return The endpoint reference.
*/
private static W3CEndpointReference getParticipantCompletionParticipant(final String id) {
final ServiceRegistry serviceRegistry = ServiceRegistry.getRegistry();
final String serviceURI = serviceRegistry.getServiceURI(BusinessActivityConstants.PARTICIPANT_COMPLETION_PARTICIPANT_SERVICE_NAME);
final W3CEndpointReferenceBuilder builder = new W3CEndpointReferenceBuilder();
builder.serviceName(BusinessActivityConstants.PARTICIPANT_COMPLETION_PARTICIPANT_SERVICE_QNAME);
builder.endpointName(BusinessActivityConstants.PARTICIPANT_COMPLETION_PARTICIPANT_PORT_QNAME);
builder.address(serviceURI);
InstanceIdentifier.setEndpointInstanceIdentifier(builder, id);
return builder.build();
}
use of com.arjuna.webservices11.ServiceRegistry in project narayana by jbosstm.
the class ActivationCoordinatorInitialisation method startup.
public static void startup() {
final ServiceRegistry serviceRegistry = PrivilegedServiceRegistryFactory.getInstance().getServiceRegistry();
WSCEnvironmentBean wscEnvironmentBean = XTSPropertyManager.getWSCEnvironmentBean();
String bindAddress = wscEnvironmentBean.getBindAddress11();
int bindPort = wscEnvironmentBean.getBindPort11();
int secureBindPort = wscEnvironmentBean.getBindPortSecure11();
String serviceURLPath = wscEnvironmentBean.getServiceURLPath();
if (serviceURLPath == null) {
serviceURLPath = "/ws-c11";
}
if (bindAddress == null) {
bindAddress = "localhost";
}
if (bindPort == 0) {
bindPort = 8080;
}
if (secureBindPort == 0) {
secureBindPort = 8443;
}
final String baseUri = "http://" + bindAddress + ":" + bindPort + serviceURLPath;
final String uri = baseUri + "/ActivationService";
final String secureBaseUri = "https://" + bindAddress + ":" + secureBindPort + serviceURLPath;
final String secureUri = secureBaseUri + "/ActivationService";
serviceRegistry.registerServiceProvider(CoordinationConstants.ACTIVATION_SERVICE_NAME, uri);
serviceRegistry.registerSecureServiceProvider(CoordinationConstants.ACTIVATION_SERVICE_NAME, secureUri);
}
use of com.arjuna.webservices11.ServiceRegistry in project narayana by jbosstm.
the class RegistrationCoordinatorInitialisation method startup.
/**
* The context has been initialized.
* @param servletContextEvent The servlet context event.
*/
public static void startup() {
// TODO work out how to configure the endpoint name here
final ServiceRegistry serviceRegistry = PrivilegedServiceRegistryFactory.getInstance().getServiceRegistry();
WSCEnvironmentBean wscEnvironmentBean = XTSPropertyManager.getWSCEnvironmentBean();
String bindAddress = wscEnvironmentBean.getBindAddress11();
int bindPort = wscEnvironmentBean.getBindPort11();
int secureBindPort = wscEnvironmentBean.getBindPortSecure11();
String serviceURLPath = wscEnvironmentBean.getServiceURLPath();
if (serviceURLPath == null) {
serviceURLPath = "/ws-c11";
}
if (bindAddress == null) {
bindAddress = "localhost";
}
if (bindPort == 0) {
bindPort = 8080;
}
if (secureBindPort == 0) {
secureBindPort = 8443;
}
final String baseUri = "http://" + bindAddress + ":" + bindPort + serviceURLPath;
final String uri = baseUri + "/RegistrationService";
final String secureBaseUri = "https://" + bindAddress + ":" + secureBindPort + serviceURLPath;
final String secureUri = secureBaseUri + "/RegistrationService";
serviceRegistry.registerServiceProvider(CoordinationConstants.REGISTRATION_SERVICE_NAME, uri);
serviceRegistry.registerSecureServiceProvider(CoordinationConstants.REGISTRATION_SERVICE_NAME, secureUri);
;
}
use of com.arjuna.webservices11.ServiceRegistry in project narayana by jbosstm.
the class CoordinatorInitialisation method startup.
public static void startup() {
final ServiceRegistry serviceRegistry = PrivilegedServiceRegistryFactory.getInstance().getServiceRegistry();
WSCEnvironmentBean wscEnvironmentBean = XTSPropertyManager.getWSCEnvironmentBean();
String bindAddress = wscEnvironmentBean.getBindAddress11();
int bindPort = wscEnvironmentBean.getBindPort11();
int secureBindPort = wscEnvironmentBean.getBindPortSecure11();
WSTEnvironmentBean wstEnvironmentBean = XTSPropertyManager.getWSTEnvironmentBean();
String coordinatorServiceURLPath = wstEnvironmentBean.getCoordinatorServiceURLPath();
if (coordinatorServiceURLPath == null) {
coordinatorServiceURLPath = "/ws-t11-coordinator";
}
if (bindAddress == null) {
bindAddress = "localhost";
}
if (bindPort == 0) {
bindPort = 8080;
}
if (secureBindPort == 0) {
secureBindPort = 8443;
}
final String baseUri = "http://" + bindAddress + ":" + bindPort + coordinatorServiceURLPath;
final String uri = baseUri + "/" + AtomicTransactionConstants.COORDINATOR_SERVICE_NAME;
final String secureBaseUri = "https://" + bindAddress + ":" + secureBindPort + coordinatorServiceURLPath;
final String secureUri = secureBaseUri + "/" + AtomicTransactionConstants.COORDINATOR_SERVICE_NAME;
serviceRegistry.registerServiceProvider(AtomicTransactionConstants.COORDINATOR_SERVICE_NAME, uri);
serviceRegistry.registerSecureServiceProvider(AtomicTransactionConstants.COORDINATOR_SERVICE_NAME, secureUri);
}
use of com.arjuna.webservices11.ServiceRegistry in project narayana by jbosstm.
the class TerminationCoordinatorInitialisation method startup.
public static void startup() {
final ServiceRegistry serviceRegistry = PrivilegedServiceRegistryFactory.getInstance().getServiceRegistry();
WSCEnvironmentBean wscEnvironmentBean = XTSPropertyManager.getWSCEnvironmentBean();
String bindAddress = wscEnvironmentBean.getBindAddress11();
int bindPort = wscEnvironmentBean.getBindPort11();
int secureBindPort = wscEnvironmentBean.getBindPortSecure11();
WSTEnvironmentBean wstEnvironmentBean = XTSPropertyManager.getWSTEnvironmentBean();
String coordinatorServiceURLPath = wstEnvironmentBean.getCoordinatorServiceURLPath();
if (coordinatorServiceURLPath == null) {
coordinatorServiceURLPath = "/ws-t11-coordinator";
}
if (bindAddress == null) {
bindAddress = "localhost";
}
if (bindPort == 0) {
bindPort = 8080;
}
if (secureBindPort == 0) {
secureBindPort = 8443;
}
final String baseUri = "http://" + bindAddress + ":" + bindPort + coordinatorServiceURLPath;
final String uri = baseUri + "/" + ArjunaTX11Constants.TERMINATION_COORDINATOR_SERVICE_NAME;
final String secureBaseUri = "https://" + bindAddress + ":" + secureBindPort + coordinatorServiceURLPath;
final String secureUri = secureBaseUri + "/" + ArjunaTX11Constants.TERMINATION_COORDINATOR_SERVICE_NAME;
serviceRegistry.registerServiceProvider(ArjunaTX11Constants.TERMINATION_COORDINATOR_SERVICE_NAME, uri);
serviceRegistry.registerSecureServiceProvider(ArjunaTX11Constants.TERMINATION_COORDINATOR_SERVICE_NAME, secureUri);
}
Aggregations