|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.hazelcast.map.impl.MapService
public class MapService
Defines map service behavior.
MapManagedService,
MapMigrationAwareService,
MapTransactionalService,
MapRemoteService,
MapEventPublishingService,
MapPostJoinAwareService,
MapSplitBrainHandlerService,
MapReplicationSupportingService,
MapStatisticsAwareService,
MapPartitionAwareService,
MapQuorumAwareService,
MapClientAwareService,
MapServiceContext| Field Summary | |
|---|---|
protected ClientAwareService |
clientAwareService
|
protected EventPublishingService |
eventPublishingService
|
protected ManagedService |
managedService
|
protected MapServiceContext |
mapServiceContext
|
protected MigrationAwareService |
migrationAwareService
|
protected PartitionAwareService |
partitionAwareService
|
protected PostJoinAwareService |
postJoinAwareService
|
protected QuorumAwareService |
quorumAwareService
|
protected RemoteService |
remoteService
|
protected ReplicationSupportingService |
replicationSupportingService
|
static String |
SERVICE_NAME
Service name of map service used to register ServiceManager.registerService(java.lang.String, java.lang.Object) |
protected SplitBrainHandlerService |
splitBrainHandlerService
|
protected StatisticsAwareService |
statisticsAwareService
|
protected TransactionalService |
transactionalService
|
| Constructor Summary | |
|---|---|
MapService()
|
|
| Method Summary | ||
|---|---|---|
void |
beforeMigration(PartitionMigrationEvent event)
|
|
void |
clearPartitionReplica(int partitionId)
|
|
void |
clientDisconnected(String clientUuid)
Invoked when a client disconnects from a member. |
|
void |
commitMigration(PartitionMigrationEvent event)
|
|
DistributedObject |
createDistributedObject(String objectName)
Creates a distributed object. |
|
|
createTransactionalObject(String name,
TransactionSupport transaction)
|
|
void |
destroyDistributedObject(String objectName)
Destroys a distributed object. |
|
void |
dispatchEvent(EventData event,
ListenerAdapter listener)
|
|
MapServiceContext |
getMapServiceContext()
|
|
Operation |
getPostJoinOperation()
Post join operations must be lock free, meaning no locks at all: no partition locks, no key-based locks, no service level locks, no database interaction! |
|
String |
getQuorumName(String name)
|
|
Map<String,LocalMapStats> |
getStats()
|
|
void |
init(NodeEngine nodeEngine,
Properties properties)
Initializes this ManagedService |
|
void |
onPartitionLost(InternalPartitionLostEvent partitionLostEvent)
Invoked when a partition lost is detected |
|
void |
onReplicationEvent(WanReplicationEvent replicationEvent)
|
|
Runnable |
prepareMergeRunnable()
When the 2 separate clusters merge (resolve a split brain), this method is called to return a Runnable that will merge the clusters. |
|
Operation |
prepareReplicationOperation(PartitionReplicationEvent event)
|
|
void |
reset()
reset this ManagedService back to initial state. |
|
void |
rollbackMigration(PartitionMigrationEvent event)
|
|
void |
rollbackTransaction(String transactionId)
|
|
void |
shutdown(boolean terminate)
Shuts down this ManagedService. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String SERVICE_NAME
ServiceManager.registerService(java.lang.String, java.lang.Object)
protected ManagedService managedService
protected MigrationAwareService migrationAwareService
protected TransactionalService transactionalService
protected RemoteService remoteService
protected EventPublishingService eventPublishingService
protected PostJoinAwareService postJoinAwareService
protected SplitBrainHandlerService splitBrainHandlerService
protected ReplicationSupportingService replicationSupportingService
protected StatisticsAwareService statisticsAwareService
protected PartitionAwareService partitionAwareService
protected ClientAwareService clientAwareService
protected QuorumAwareService quorumAwareService
protected MapServiceContext mapServiceContext
| Constructor Detail |
|---|
public MapService()
| Method Detail |
|---|
public void dispatchEvent(EventData event,
ListenerAdapter listener)
dispatchEvent in interface EventPublishingService<EventData,ListenerAdapter>
public void init(NodeEngine nodeEngine,
Properties properties)
ManagedService
init in interface ManagedServicenodeEngine - the NodeEngine that this ManagedService belongs to.properties - the Properties. Can be used to pass settings to the service.public void reset()
ManagedService
reset in interface ManagedServicepublic void shutdown(boolean terminate)
ManagedService
shutdown in interface ManagedServiceterminate - true to shut down the 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)
RemoteService
createDistributedObject in interface RemoteServiceobjectName - the name for the created distributed object
public void destroyDistributedObject(String objectName)
RemoteService
destroyDistributedObject in interface RemoteServiceobjectName - the name of the distributed object to destroypublic void onReplicationEvent(WanReplicationEvent replicationEvent)
onReplicationEvent in interface ReplicationSupportingServicepublic void onPartitionLost(InternalPartitionLostEvent partitionLostEvent)
PartitionAwareService
onPartitionLost in interface PartitionAwareServicepartitionLostEvent - The event object that contains the partition id and the number of replicas that is lostpublic Runnable prepareMergeRunnable()
SplitBrainHandlerService
prepareMergeRunnable in interface SplitBrainHandlerService
public <T extends TransactionalObject> T createTransactionalObject(String name,
TransactionSupport transaction)
createTransactionalObject in interface TransactionalServicepublic void rollbackTransaction(String transactionId)
rollbackTransaction in interface TransactionalServicepublic Map<String,LocalMapStats> getStats()
getStats in interface StatisticsAwareServicepublic String getQuorumName(String name)
getQuorumName in interface QuorumAwareServicepublic MapServiceContext getMapServiceContext()
public void clientDisconnected(String clientUuid)
ClientAwareService
clientDisconnected in interface ClientAwareServiceclientUuid - the Uuid of the client that disconnected from a member
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||