Class TransactionalPersistenceEventManager
- java.lang.Object
-
- org.jbpm.persistence.api.integration.base.TransactionalPersistenceEventManager
-
- All Implemented Interfaces:
PersistenceEventManager
public class TransactionalPersistenceEventManager extends Object implements PersistenceEventManager
Default implementation ofPersistenceEventManagerthat binds into transaction to secure delivery of events to be consistent with persistence layer.
-
-
Field Summary
Fields Modifier and Type Field Description protected org.drools.persistence.api.TransactionManagertm
-
Constructor Summary
Constructors Constructor Description TransactionalPersistenceEventManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Requests to close the manager and underlying resources e.g. emittervoidcreate(InstanceView<?> item)Invoked by persistence layer when new instance is createdvoiddelete(InstanceView<?> item)Invoked by persistence layer when instance is deletedprotected EventCollectiongetCollection()booleanisActive()Determines if event manager is actually active (there is emitter found)protected voidregisterSync()voidsetEventEmitter(EventEmitter eventEmitter)Override programmatically the emitter foundvoidupdate(InstanceView<?> item)Invoked by persistence layer when instance is updated
-
-
-
Method Detail
-
setEventEmitter
public void setEventEmitter(EventEmitter eventEmitter)
Description copied from interface:PersistenceEventManagerOverride programmatically the emitter found- Specified by:
setEventEmitterin interfacePersistenceEventManager
-
create
public void create(InstanceView<?> item)
Description copied from interface:PersistenceEventManagerInvoked by persistence layer when new instance is created- Specified by:
createin interfacePersistenceEventManager- Parameters:
item- view of the actual instance
-
update
public void update(InstanceView<?> item)
Description copied from interface:PersistenceEventManagerInvoked by persistence layer when instance is updated- Specified by:
updatein interfacePersistenceEventManager- Parameters:
item- view of the actual instance
-
delete
public void delete(InstanceView<?> item)
Description copied from interface:PersistenceEventManagerInvoked by persistence layer when instance is deleted- Specified by:
deletein interfacePersistenceEventManager- Parameters:
item- view of the actual instance
-
isActive
public boolean isActive()
Description copied from interface:PersistenceEventManagerDetermines if event manager is actually active (there is emitter found)- Specified by:
isActivein interfacePersistenceEventManager
-
getCollection
protected EventCollection getCollection()
-
registerSync
protected void registerSync()
-
close
public void close()
Description copied from interface:PersistenceEventManagerRequests to close the manager and underlying resources e.g. emitter- Specified by:
closein interfacePersistenceEventManager
-
-