public interface ISyncService extends IFloodlightService
JsonNode
will avoid this
problem. Using strings as keys also avoids this problem.Modifier and Type | Interface and Description |
---|---|
static class |
ISyncService.Scope |
Modifier and Type | Method and Description |
---|---|
void |
addRPCListener(IRPCListener listener)
Listener to RPC connections, used in simple Fault tolerance module,
or other modules that need cluster monitor nodes (connect and disconnect).
|
short |
getLocalNodeId() |
<K,V> IStoreClient<K,V> |
getStoreClient(java.lang.String storeName,
java.lang.Class<K> keyClass,
java.lang.Class<V> valueClass)
Get a store client for the given store.
|
<K,V> IStoreClient<K,V> |
getStoreClient(java.lang.String storeName,
java.lang.Class<K> keyClass,
java.lang.Class<V> valueClass,
IInconsistencyResolver<Versioned<V>> resolver)
Get a store client that will use the provided inconsistency resolver
to resolve concurrent updates.
|
<K,V> IStoreClient<K,V> |
getStoreClient(java.lang.String storeName,
com.fasterxml.jackson.core.type.TypeReference<K> keyType,
com.fasterxml.jackson.core.type.TypeReference<V> valueType)
Get a store client for the given store.
|
<K,V> IStoreClient<K,V> |
getStoreClient(java.lang.String storeName,
com.fasterxml.jackson.core.type.TypeReference<K> keyType,
com.fasterxml.jackson.core.type.TypeReference<V> valueType,
IInconsistencyResolver<Versioned<V>> resolver)
Get a store client that will use the provided inconsistency resolver
to resolve concurrent updates.
|
void |
registerPersistentStore(java.lang.String storeName,
ISyncService.Scope scope)
Create a store with the given store name and scope that will be
persistent across reboots.
|
void |
registerStore(java.lang.String storeName,
ISyncService.Scope scope)
Create a store with the given store name and scope
|
void |
removeRPCListener(IRPCListener listener) |
short getLocalNodeId()
void registerStore(java.lang.String storeName, ISyncService.Scope scope) throws SyncException
storeName
- the name of the storescope
- the distribution scope for the dataSyncException
void registerPersistentStore(java.lang.String storeName, ISyncService.Scope scope) throws SyncException
storeName
- the name of the storescope
- the distribution scope for the dataSyncException
<K,V> IStoreClient<K,V> getStoreClient(java.lang.String storeName, java.lang.Class<K> keyClass, java.lang.Class<V> valueClass) throws UnknownStoreException
storeName
- the name of the store to retrievekeyClass
- the class for the underlying key needed for
deserializationvalueClass
- the class for the underlying value needed for
deserializationUnknownStoreException
<K,V> IStoreClient<K,V> getStoreClient(java.lang.String storeName, java.lang.Class<K> keyClass, java.lang.Class<V> valueClass, IInconsistencyResolver<Versioned<V>> resolver) throws UnknownStoreException
storeName
- the name of the store to retrievekeyClass
- the class for the underlying key needed for
deserializationvalueClass
- the class for the underlying value needed for
deserializationresolver
- the inconsistency resolver to use for the storeUnknownStoreException
<K,V> IStoreClient<K,V> getStoreClient(java.lang.String storeName, com.fasterxml.jackson.core.type.TypeReference<K> keyType, com.fasterxml.jackson.core.type.TypeReference<V> valueType) throws UnknownStoreException
storeName
- the name of the store to retrievekeyType
- the type reference for the underlying key needed for
deserializationvalueType
- the type reference for the underlying value needed for
deserializationUnknownStoreException
<K,V> IStoreClient<K,V> getStoreClient(java.lang.String storeName, com.fasterxml.jackson.core.type.TypeReference<K> keyType, com.fasterxml.jackson.core.type.TypeReference<V> valueType, IInconsistencyResolver<Versioned<V>> resolver) throws UnknownStoreException
storeName
- the name of the store to retrievekeyType
- the type reference for the underlying key needed for
deserializationvalueType
- the type reference for the underlying value needed for
deserializationresolver
- the inconsistency resolver to use for the storeUnknownStoreException
void addRPCListener(IRPCListener listener)
listener
- void removeRPCListener(IRPCListener listener)