Use cache in map register message. 03/38103/34
authorJozef Gloncak <jgloncak@cisco.com>
Tue, 26 Apr 2016 09:20:53 +0000 (11:20 +0200)
committerJozef Gloncak <jgloncak@cisco.com>
Thu, 19 May 2016 11:46:10 +0000 (13:46 +0200)
commit072838407d20d5b1e45e1625289dc20f94c750ef
treeb01266a784f035b63bff581a2f05ac0b1ee9e4a1
parentc65742f634d79a8779925093ead36c274e86959c
Use cache in map register message.

Map register messages are stored to special cache (hash map).

Key for this has map consists of eid-prefix, site-id and xtr-id.
Components of key are stored as byte arrays.

Value part of cache entry contains transformed value from key
(site-id and xtr-id and complete list of eid-prefixes). Additionaly
there is also timestamp (time of creation or refresh the cache entry),
want-map-notify value and complete original value of received map
register message.

Also new type of message mapping-keep-alive is added. This
notification is raised if map-register message is received and is
found in cache.

At the end if map-notify-bit is set then also notify message is
directly generated from southbound.

Change-Id: I6c5ba8e6ff226d5f4a7b5964159dc138a4bbfc33
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
mappingservice/implementation/src/main/java/org/opendaylight/lispflowmapping/implementation/LispMappingService.java
mappingservice/southbound/src/main/java/org/opendaylight/lispflowmapping/southbound/LispSouthboundPlugin.java
mappingservice/southbound/src/main/java/org/opendaylight/lispflowmapping/southbound/lisp/LispSouthboundHandler.java
mappingservice/southbound/src/main/java/org/opendaylight/lispflowmapping/southbound/lisp/cache/MapRegisterCache.java [new file with mode: 0644]
mappingservice/southbound/src/main/java/org/opendaylight/lispflowmapping/southbound/lisp/cache/MapRegisterPartialDeserializer.java [new file with mode: 0644]
mappingservice/southbound/src/site/markdown/map-register_cache.md
mappingservice/southbound/src/test/java/org/opendaylight/lispflowmapping/southbound/lisp/LispSouthboundServiceTest.java
mappingservice/southbound/src/test/java/org/opendaylight/lispflowmapping/southbound/lisp/MapRegisterCacheTestUtil.java [new file with mode: 0644]