Merge pull request #189 from aluzzardi/node-events

Events: Embed the entire Node object rather than its attributes.
Cluster: Maintain a per-node container list.

Instead of querying the nodes to collect the list of containers,
maintain a local per-node container list and refresh it whenever
receiving events for said node.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Add a VirtualId to Container.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Cluster: Lock the mutex while updating the list of containers.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Virtual ID mapping for containers.

Instead of exposing the raw container ID from the node, Cluster
maps a Virtual ID to every container and the API makes sure to expose it
in lieu of the ID.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Container: Make Node public instead of exposing it through Node().

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Add a simple key<->Container persistent store.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Store VirtualID <-> ID mapping persistently.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
generateVirtualID -> generateVirtualId.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Remove store data after tests are finished.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>