public class SagaEntry extends Object
Constructor and Description |
---|
SagaEntry(com.mongodb.DBObject dbSaga)
Initializes a Saga entry using a DBObject containing the Mongo Document
|
SagaEntry(Saga saga,
Serializer serializer)
Constructs a new SagaEntry for the given
saga . |
Modifier and Type | Method and Description |
---|---|
com.mongodb.DBObject |
asDBObject()
Returns the Mongo Document representing the Saga provided in this entry.
|
Saga |
getSaga(Serializer serializer)
Returns the Saga instance stored in this entry.
|
static com.mongodb.DBObject |
queryByIdentifier(String identifier)
Returns the Mongo Query to find a Saga based on its identifier.
|
public SagaEntry(Saga saga, Serializer serializer)
saga
. The given saga must be serializable. The provided
saga is not modified by this operation.saga
- The saga to storeserializer
- The serialization mechanism to convert the Saga to a byte streampublic SagaEntry(com.mongodb.DBObject dbSaga)
dbSaga
- The mongo Document containing the serialized sagapublic Saga getSaga(Serializer serializer)
serializer
- The serializer to decode the Sagapublic com.mongodb.DBObject asDBObject()
public static com.mongodb.DBObject queryByIdentifier(String identifier)
identifier
- The identifier of the saga to findCopyright © 2010-2014. All Rights Reserved.