public class MongoDBEntityStoreMixin extends Object implements ServiceActivation, MapEntityStore, MongoDBAccessors
ServiceActivation.ServiceActivatorMapEntityStore.MapChange, MapEntityStore.MapChanger, MapEntityStore.MapChanges| Modifier and Type | Field and Description |
|---|---|
static String |
IDENTITY_COLUMN |
static String |
STATE_COLUMN |
| Constructor and Description |
|---|
MongoDBEntityStoreMixin() |
| Modifier and Type | Method and Description |
|---|---|
void |
activateService()
Called after ServiceComposite Activation.
|
void |
applyChanges(MapEntityStore.MapChanges changes) |
String |
collectionUsed() |
com.mongodb.client.MongoDatabase |
dbInstanceUsed() |
Stream<Reader> |
entityStates() |
Reader |
get(EntityReference entityReference) |
com.mongodb.MongoClient |
mongoInstanceUsed() |
void |
passivateService()
Called before ServiceComposite Passivation.
|
public static final String IDENTITY_COLUMN
public static final String STATE_COLUMN
public void activateService()
throws Exception
ServiceActivationactivateService in interface ServiceActivationException - if unable to activatepublic void passivateService()
throws Exception
ServiceActivationpassivateService in interface ServiceActivationException - if unable to passivatepublic com.mongodb.MongoClient mongoInstanceUsed()
mongoInstanceUsed in interface MongoDBAccessorspublic com.mongodb.client.MongoDatabase dbInstanceUsed()
dbInstanceUsed in interface MongoDBAccessorspublic String collectionUsed()
collectionUsed in interface MongoDBAccessorspublic Reader get(EntityReference entityReference) throws EntityStoreException
get in interface MapEntityStoreentityReference - The reference to the entity that we want to get.EntityStoreExceptionpublic void applyChanges(MapEntityStore.MapChanges changes) throws Exception
applyChanges in interface MapEntityStoreExceptionpublic Stream<Reader> entityStates()
entityStates in interface MapEntityStore