BUG-994: improve object cache

This fixes the object cache to work in face of missing concrete
implementation. Also fixes up previous mistakes in cache interaction,
adding tests.

Change-Id: Icd041045ab360630788775c2e6a3ed091c527029
Signed-off-by: Robert Varga <rovarga@cisco.com>