com.sun.xml.ws.tx.coordinator
Class RegistrationManager

java.lang.Object
  extended by com.sun.xml.ws.tx.coordinator.RegistrationManager

public final class RegistrationManager
extends java.lang.Object

This singleton class handles the register and registerResponse operations for both local and remote (or external) clients. The exposed web service endpoints for register and registerResponse delegate to the methods in this class.

Since:
1.0

Method Summary
static RegistrationManager getInstance()
          Get the singleton instance of the RegistrationManager
static java.net.URI getLocalAsyncRegistrationURI()
           
static java.net.URI getLocalRegistrationRequesterURI()
           
static java.net.URI getLocalRegistrationURI()
           
static com.sun.xml.ws.developer.StatefulWebServiceManager getRegistrationCoordinatorStatefulWebServiceManager()
           
static javax.xml.ws.EndpointReference newRegistrationEPR(ActivityIdentifier activityId, long timeoutInMillis)
          Create a new EPR for our registration service.
 void register(Coordinator c, Registrant r)
          This is the local entry point for register.
 void register(javax.xml.ws.WebServiceContext wsContext, java.lang.String activityId, RegisterType registerRequest)
          Handle an incoming web service request from an external Participant and send a back.
 void registerResponse(javax.xml.ws.WebServiceContext wsContext, java.lang.String activityId, java.lang.String registrantId, RegisterResponseType registerResponse)
          Process an incoming message.
static RegisterResponseType synchronousRegister(javax.xml.ws.WebServiceContext wsContext, java.lang.String activityId, RegisterType registerRequest)
          Handling incoming synchronous and return .
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLocalRegistrationURI

public static java.net.URI getLocalRegistrationURI()

getLocalAsyncRegistrationURI

public static java.net.URI getLocalAsyncRegistrationURI()

getLocalRegistrationRequesterURI

public static java.net.URI getLocalRegistrationRequesterURI()

newRegistrationEPR

public static javax.xml.ws.EndpointReference newRegistrationEPR(ActivityIdentifier activityId,
                                                                long timeoutInMillis)
Create a new EPR for our registration service.

Note: as a side-effect, this method creates a stateful instance of the registration service that will handle correlation when a client actually registers with us. Should we consider moving this code to point of use (ie during coordination context creation)?

Parameters:
activityId - the coordination id for this activity, maintained as state in the registration service
timeoutInMillis - the expiration value for this context
Returns:
an EPR containing the address of our registration service

getRegistrationCoordinatorStatefulWebServiceManager

public static com.sun.xml.ws.developer.StatefulWebServiceManager getRegistrationCoordinatorStatefulWebServiceManager()

getInstance

public static RegistrationManager getInstance()
Get the singleton instance of the RegistrationManager

Returns:
the RegistrationManager

register

public void register(@NotNull
                     javax.xml.ws.WebServiceContext wsContext,
                     @NotNull
                     java.lang.String activityId,
                     @NotNull
                     RegisterType registerRequest)
Handle an incoming web service request from an external Participant and send a back.

Parameters:
wsContext - webservice context
registerRequest - the incoming request
activityId - activity id

register

public void register(Coordinator c,
                     Registrant r)
This is the local entry point for register. Depending on the root registration service contained in the coordinator, this method will either invoke registerOperation on a remote registration service or simply register locally with our registration service.

Parameters:
c - Coordinator
r - registrant

registerResponse

public void registerResponse(@NotNull
                             javax.xml.ws.WebServiceContext wsContext,
                             @NotNull
                             java.lang.String activityId,
                             @NotNull
                             java.lang.String registrantId,
                             @NotNull
                             RegisterResponseType registerResponse)
Process an incoming message.

Parameters:
activityId - activity id
registrantId - registrant id
registerResponse - message
wsContext - context of the inbound web service invocation

synchronousRegister

@NotNull
public static RegisterResponseType synchronousRegister(@NotNull
                                                               javax.xml.ws.WebServiceContext wsContext,
                                                               @NotNull
                                                               java.lang.String activityId,
                                                               @NotNull
                                                               RegisterType registerRequest)
Handling incoming synchronous and return .

Parameters:
activityId - activity id
registerRequest - request
wsContext - context for incoming web service invocation
Returns:
a new