public class MappingSystem extends Object implements IMappingSystem
| Constructor and Description |
|---|
MappingSystem(ILispDAO dao,
boolean iterateMask,
org.opendaylight.controller.md.sal.binding.api.NotificationPublishService nps,
boolean mappingMerge) |
| Modifier and Type | Method and Description |
|---|---|
void |
addAuthenticationKey(Eid key,
MappingAuthkey authKey)
Add authentication key.
|
void |
addData(MappingOrigin origin,
Eid key,
String subKey,
Object data)
Add data for key.
|
void |
addMapping(MappingOrigin origin,
Eid key,
MappingData mappingData)
Add mapping.
|
MappingData |
addNegativeMapping(Eid key)
Generate and add a negative mapping entry originated from the southbound, and return the generated mapping.
|
void |
cleanCaches() |
void |
cleanSBMappings() |
void |
destroy() |
MappingAuthkey |
getAuthenticationKey(Eid key)
Retrieve authentication key.
|
Object |
getData(MappingOrigin origin,
Eid key,
String subKey)
Generic retrieval of data.
|
MappingData |
getMapping(Eid dst)
Retrieves mapping for the provided dst key.
|
MappingData |
getMapping(Eid src,
Eid dst)
Retrieves mapping for the provided src and dst key.
|
MappingData |
getMapping(Eid src,
Eid dst,
XtrId xtrId)
Retrieves mapping for the provided dst key for a particular xtr id.
|
MappingData |
getMapping(MappingOrigin origin,
Eid key)
Retrieves mapping from table for provided key.
|
Eid |
getParentPrefix(Eid key)
Returns the parent prefix for given key.
|
Set<Subscriber> |
getSubscribers(Eid address)
Retrieves the subscribers for an EID.
|
Set<Eid> |
getSubtree(MappingOrigin origin,
Eid key)
Retrieves the subtree of a maskable prefix from the given map-cache.
|
Eid |
getWidestNegativePrefix(Eid key)
Retrieves widest negative prefix from table for provided key.
|
MappingData |
handleSbExpiredMapping(Eid key,
XtrId xtrId,
MappingData mappingData) |
void |
initialize() |
boolean |
isMaster()
Get cluster master status.
|
void |
notifyChange(Eid eid,
MappingRecord mapping,
MappingChange mappingChange) |
String |
prettyPrintKeys()
Print keys in cache in a human friendly format.
|
String |
prettyPrintMappings()
Print mappings in cache in a human friendly format.
|
String |
printKeys()
Print all authentication keys.
|
String |
printMappings()
Print all mappings.
|
void |
refreshMappingRegistration(Eid key,
XtrId xtrId,
Long timestamp)
Refresh southbound mapping registration timestamp.
|
void |
removeAuthenticationKey(Eid key)
Remove authentication key.
|
void |
removeData(MappingOrigin origin,
Eid key,
String subKey)
Generic removal of data.
|
void |
removeMapping(MappingOrigin origin,
Eid key)
Remove mapping.
|
void |
setDataStoreBackEnd(DataStoreBackEnd dataStoreBackEnd) |
void |
setIsMaster(boolean isMaster)
Set cluster master status.
|
void |
setIterateMask(boolean iterate)
Sets iterateMask.
|
void |
setMappingMerge(boolean mappingMerge)
Configure merge policy.
|
void |
subscribe(Subscriber subscriber,
Eid subscribedEid)
Subscribe a Subscriber to receive updates about mapping changes for an EID.
|
void |
updateMapping(MappingOrigin origin,
Eid key,
MappingData mappingData)
Update mapping.
|
public MappingSystem(ILispDAO dao, boolean iterateMask, org.opendaylight.controller.md.sal.binding.api.NotificationPublishService nps, boolean mappingMerge)
public void setDataStoreBackEnd(DataStoreBackEnd dataStoreBackEnd)
public void setMappingMerge(boolean mappingMerge)
IMappingSystemsetMappingMerge in interface IMappingSystemmappingMerge - Value to configurepublic void setIterateMask(boolean iterate)
IMappingSystemsetIterateMask in interface IMappingSystemiterate - Value to configurepublic void initialize()
public void updateMapping(MappingOrigin origin, Eid key, MappingData mappingData)
IMappingSystemupdateMapping in interface IMappingSystemorigin - Table where mapping should be addedkey - Key of the mappingmappingData - Mapping to be storedpublic void addMapping(MappingOrigin origin, Eid key, MappingData mappingData)
IMappingSystemaddMapping in interface IMappingSystemorigin - Table where mapping should be addedkey - Key of the mappingmappingData - Mapping to be storedpublic MappingData addNegativeMapping(Eid key)
IMappingSystemaddNegativeMapping in interface IMappingSystemkey - Key of the mappingpublic void refreshMappingRegistration(Eid key, XtrId xtrId, Long timestamp)
IMappingSystemrefreshMappingRegistration in interface IMappingSystemkey - The EID whose registration must be refreshedxtrId - xTR-ID of the mapping to be refreshedtimestamp - New timestamp for the mappingpublic MappingData getMapping(Eid src, Eid dst)
IMappingSystemgetMapping in interface IMappingSystemsrc - Source Key to be looked updst - Destination Key to be looked uppublic MappingData getMapping(Eid dst)
IMappingSystemgetMapping in interface IMappingSystemdst - Destination Key to be looked uppublic MappingData getMapping(Eid src, Eid dst, XtrId xtrId)
IMappingSystemgetMapping in interface IMappingSystemsrc - Source Key to be looked up.dst - Destination Key to be looked up.xtrId - Xtr Id for which this look to be done. If null, this method works like
regular getMapping(src, dst)public MappingData getMapping(MappingOrigin origin, Eid key)
IMappingSystemgetMapping in interface IMappingSystemorigin - Table where mapping should be looked upkey - Key to be looked uppublic MappingData handleSbExpiredMapping(Eid key, XtrId xtrId, MappingData mappingData)
public Eid getWidestNegativePrefix(Eid key)
IMappingSystemgetWidestNegativePrefix in interface IMappingSystemkey - Key to be looked uppublic Set<Eid> getSubtree(MappingOrigin origin, Eid key)
IMappingSystemgetSubtree in interface IMappingSystemorigin - Table where the key should be looked upkey - Key to be looked uppublic void removeMapping(MappingOrigin origin, Eid key)
IMappingSystemremoveMapping in interface IMappingSystemorigin - Table for mapping that should be removedkey - Key to be removedpublic void notifyChange(Eid eid, MappingRecord mapping, MappingChange mappingChange)
public void subscribe(Subscriber subscriber, Eid subscribedEid)
IMappingSystemsubscribe in interface IMappingSystemsubscriber - The Subscriber object with information about the subscribersubscribedEid - The EID for which the subscriber will receive updatespublic Set<Subscriber> getSubscribers(Eid address)
IMappingSystemgetSubscribers in interface IMappingSystemaddress - The EID to be looked uppublic void addAuthenticationKey(Eid key, MappingAuthkey authKey)
IMappingSystemaddAuthenticationKey in interface IMappingSystemkey - The key for which the authentication key is addedauthKey - The authentication keypublic MappingAuthkey getAuthenticationKey(Eid key)
IMappingSystemgetAuthenticationKey in interface IMappingSystemkey - The key for which the authentication key is being looked up.public void removeAuthenticationKey(Eid key)
IMappingSystemremoveAuthenticationKey in interface IMappingSystemkey - Key for which the authentication key should be removed.public void addData(MappingOrigin origin, Eid key, String subKey, Object data)
IMappingSystemaddData in interface IMappingSystemorigin - Table for data that should be addedkey - The key for which data is insertedsubKey - The subKey where data should be inserteddata - The data to be storedpublic Object getData(MappingOrigin origin, Eid key, String subKey)
IMappingSystemgetData in interface IMappingSystemorigin - Table from where data should be retrievedkey - The key where the data is storedsubKey - The subKey where data is storedpublic void removeData(MappingOrigin origin, Eid key, String subKey)
IMappingSystemremoveData in interface IMappingSystemorigin - Table from where data should be removedkey - The key of the data to be removedsubKey - The subKey of the data to be removedpublic Eid getParentPrefix(Eid key)
IMappingSystemgetParentPrefix in interface IMappingSystemkey - The key which parent is to be returned.public void destroy()
public String printMappings()
IMappingSystemprintMappings in interface IMappingSystempublic String prettyPrintMappings()
IMappingSystemprettyPrintMappings in interface IMappingSystempublic String printKeys()
IMappingSystemprintKeys in interface IMappingSystempublic String prettyPrintKeys()
IMappingSystemprettyPrintKeys in interface IMappingSystempublic void cleanCaches()
public void cleanSBMappings()
public void setIsMaster(boolean isMaster)
IMappingSystemsetIsMaster in interface IMappingSystemisMaster - is|isn't masterpublic boolean isMaster()
IMappingSystemisMaster in interface IMappingSystemCopyright © 2019 OpenDaylight. All rights reserved.