|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.alfresco.bm.event.AbstractEventService
org.alfresco.bm.event.mongo.MongoEventService
public class MongoEventService
An EventService MongoDB collection
| Constructor Summary | |
|---|---|
MongoEventService(org.springframework.data.mongodb.core.MongoTemplate mongo,
String collection)
Construct a provider that works using the given Mongo instance and collection name. |
|
| Method Summary | |
|---|---|
long |
count()
|
boolean |
deleteEvent(Event event)
Delete an event from the provider. |
List<Event> |
findEvents(String name,
int skip,
int limit)
Find any event matching the given name, using the paging criteria |
Event |
getEvent(String id)
Fetch a specific event by unique ID |
Event |
lockEvent(Event event,
String lockOwner)
Lock an event for processing by the given owner |
Event |
nextEvent(String dataOwner,
long latestScheduledTime,
long latestQueueTime)
Retrieve the next event in the queue. |
Event |
putEvent(Event event)
Adds an event to the provider. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MongoEventService(org.springframework.data.mongodb.core.MongoTemplate mongo,
String collection)
mongo - the MongoDB template to usecollection - the name of the MongoDB collection| Method Detail |
|---|
public long count()
public List<Event> findEvents(String name,
int skip,
int limit)
EventService
name - find events with the given nameskip - the number of results to skiplimit - the maximum number of results to retrieve
public Event nextEvent(String dataOwner,
long latestScheduledTime,
long latestQueueTime)
dataOwner - the identifier of the client queuing eventslatestQueueTime - the event scheduled time must not be greater than this
public Event lockEvent(Event event,
String lockOwner)
event - the event to locklockOwner - the lock owner
public Event getEvent(String id)
EventService
id - the event ID
public boolean deleteEvent(Event event)
EventService
event - the event to delete
public Event putEvent(Event event)
EventService
event - the event to add (the event ID must be null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||