public final class MapService extends Object implements ManagedService, MigrationAwareService, TransactionalService, RemoteService, EventPublishingService<EventData,EntryListener>, PostJoinAwareService, SplitBrainHandlerService, ReplicationSupportingService
MapManagedService,
MapMigrationAwareService,
MapTransactionalService,
MapRemoteService,
MapEventPublishingService,
MapPostJoinAwareService,
MapSplitBrainHandlerService,
MapReplicationSupportingService| Modifier and Type | Field and Description |
|---|---|
static String |
SERVICE_NAME
Service name of map service used
to register
ServiceManager.registerService(java.lang.String, java.lang.Object) |
| Modifier and Type | Method and Description |
|---|---|
void |
beforeMigration(PartitionMigrationEvent event) |
void |
clearPartitionReplica(int partitionId) |
void |
commitMigration(PartitionMigrationEvent event) |
static MapService |
create(NodeEngine nodeEngine)
Static factory method which creates a new map service object.
|
DistributedObject |
createDistributedObject(String objectName) |
<T extends TransactionalObject> |
createTransactionalObject(String name,
TransactionSupport transaction) |
void |
destroyDistributedObject(String objectName) |
void |
dispatchEvent(EventData event,
EntryListener listener) |
MapServiceContext |
getMapServiceContext() |
Operation |
getPostJoinOperation()
Post join operations must be lock free; means no locks at all;
no partition locks, no key-based locks, no service level locks or
no database interaction!
|
void |
init(NodeEngine nodeEngine,
Properties properties)
Initializes this ManagedService
|
void |
onReplicationEvent(WanReplicationEvent replicationEvent) |
Runnable |
prepareMergeRunnable() |
Operation |
prepareReplicationOperation(PartitionReplicationEvent event) |
void |
reset()
reset this ManagedService back to initial state.
|
void |
rollbackMigration(PartitionMigrationEvent event) |
void |
rollbackTransaction(String transactionId) |
void |
setMapServiceContext(MapServiceContext mapServiceContext) |
void |
shutdown(boolean terminate)
Shuts down this ManagedService.
|
public static final String SERVICE_NAME
ServiceManager.registerService(java.lang.String, java.lang.Object)public void dispatchEvent(EventData event, EntryListener listener)
dispatchEvent in interface EventPublishingService<EventData,EntryListener>public void init(NodeEngine nodeEngine, Properties properties)
ManagedServiceinit in interface ManagedServicenodeEngine - the NodeEngine this ManagedService belongs to.properties - the Properties. Can be used to pass settings to the service.public void reset()
ManagedServicereset in interface ManagedServicepublic void shutdown(boolean terminate)
ManagedServiceshutdown in interface ManagedServicepublic Operation prepareReplicationOperation(PartitionReplicationEvent event)
prepareReplicationOperation in interface MigrationAwareServicepublic void beforeMigration(PartitionMigrationEvent event)
beforeMigration in interface MigrationAwareServicepublic void commitMigration(PartitionMigrationEvent event)
commitMigration in interface MigrationAwareServicepublic void rollbackMigration(PartitionMigrationEvent event)
rollbackMigration in interface MigrationAwareServicepublic void clearPartitionReplica(int partitionId)
clearPartitionReplica in interface MigrationAwareServicepublic Operation getPostJoinOperation()
PostJoinAwareServicePost join operations should return response, at least a null response.
getPostJoinOperation in interface PostJoinAwareServicepublic DistributedObject createDistributedObject(String objectName)
createDistributedObject in interface RemoteServicepublic void destroyDistributedObject(String objectName)
destroyDistributedObject in interface RemoteServicepublic void onReplicationEvent(WanReplicationEvent replicationEvent)
onReplicationEvent in interface ReplicationSupportingServicepublic Runnable prepareMergeRunnable()
prepareMergeRunnable in interface SplitBrainHandlerServicepublic <T extends TransactionalObject> T createTransactionalObject(String name, TransactionSupport transaction)
createTransactionalObject in interface TransactionalServicepublic void rollbackTransaction(String transactionId)
rollbackTransaction in interface TransactionalServicepublic void setMapServiceContext(MapServiceContext mapServiceContext)
public MapServiceContext getMapServiceContext()
public static MapService create(NodeEngine nodeEngine)
nodeEngine - node engine.Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.