Package org.jboss.jbossts.star.client
Class SRAParticipant
- java.lang.Object
-
- org.jboss.jbossts.star.client.SRAParticipant
-
@RequestScoped public abstract class SRAParticipant extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description SRAParticipant()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description javax.ws.rs.core.ResponsecommitWork(java.lang.String atId, java.lang.String sraId)protected java.lang.StringgetCompensatorData(java.lang.String activityId)protected java.lang.StringgetCurrentActivityId()Get the SRA context of the currently running method.javax.ws.rs.core.ResponsegetTerminator()voidpostConstruct()javax.ws.rs.core.ResponseprepareWork(java.lang.String sraId)javax.ws.rs.core.ResponserollbackWork(java.lang.String sraId)javax.ws.rs.core.Responsestatus(java.lang.String sraId)protected abstract SRAStatusupdateParticipantState(SRAStatus status, java.lang.String activityId)
-
-
-
Method Detail
-
updateParticipantState
protected abstract SRAStatus updateParticipantState(SRAStatus status, java.lang.String activityId)
-
getCompensatorData
protected java.lang.String getCompensatorData(java.lang.String activityId)
-
getCurrentActivityId
protected java.lang.String getCurrentActivityId()
Get the SRA context of the currently running method. Note that @HeaderParam(SRA_HTTP_HEADER) does not match the header (done't know why) so we the httpRequest- Returns:
- the SRA context of the currently running method
-
getTerminator
@HEAD @Path("/participant") @Produces("application/json") public javax.ws.rs.core.Response getTerminator()
-
commitWork
@PUT @Path("/commit/{txid}") @Produces("application/json") public javax.ws.rs.core.Response commitWork(@HeaderParam("Short-Running-Action") java.lang.String atId, @PathParam("txid") java.lang.String sraId) throws javax.ws.rs.NotFoundException- Throws:
javax.ws.rs.NotFoundException
-
prepareWork
@PUT @Path("/prepare/{txid}") @Produces("application/json") public javax.ws.rs.core.Response prepareWork(@PathParam("txid") java.lang.String sraId) throws javax.ws.rs.NotFoundException- Throws:
javax.ws.rs.NotFoundException
-
rollbackWork
@PUT @Path("/rollback/{txid}") @Produces("application/json") public javax.ws.rs.core.Response rollbackWork(@PathParam("txid") java.lang.String sraId) throws javax.ws.rs.NotFoundException- Throws:
javax.ws.rs.NotFoundException
-
status
@GET @Path("/status/{txid}") @Produces("application/json") public javax.ws.rs.core.Response status(@PathParam("txid") java.lang.String sraId) throws javax.ws.rs.NotFoundException- Throws:
javax.ws.rs.NotFoundException
-
postConstruct
@PostConstruct public void postConstruct()
-
-