OAK-891 - Use DirectMemory as Level 2/Offheap cache

Adding isSealed to determine if document is sealed or not

git-svn-id: https://svn.apache.org/repos/asf/jackrabbit/oak/trunk@1560664 13f79535-47bb-0310-9956-ffa450edef68
OAK-891 - Use DirectMemory as Level 2/Offheap cache

-- Introducing a CachedNodeDocument capturing properties required for
   managing cached document
-- Sealing the NULL NodeDocument
-- Adding constructor to capture creation time. Required when NodeDocument is
   constructed via deserialization

git-svn-id: https://svn.apache.org/repos/asf/jackrabbit/oak/trunk@1560665 13f79535-47bb-0310-9956-ffa450edef68
OAK-891 - Use DirectMemory as Level 2/Offheap cache

Adding OffHeap cache support which uses Kryo and DirectMemory
-- OffHeapCache interface to remove direct dependency on DM and Kryo classes
-- Cache invalidation logic takes care of off heap cache content also
-- Care is taken to not deserialize complete NodeDocument just for cache consistency
    check.
-- Custom Kryo serializer for compact storage of NodeDocument and Revision classes
-- Off heap cache is used if off heap cache size is set to non zero value in MongoMK.Builder

git-svn-id: https://svn.apache.org/repos/asf/jackrabbit/oak/trunk@1560666 13f79535-47bb-0310-9956-ffa450edef68
OAK-891 - Use DirectMemory as Level 2/Offheap cache

Enabling support for configuring off heap cache via OSGi. Further now various
properties are also read from framework properties also. So to configure offHeapCache
size from framework property use `oak.documentstore.offHeapCache`. Similar
pattern for cache also

git-svn-id: https://svn.apache.org/repos/asf/jackrabbit/oak/trunk@1560667 13f79535-47bb-0310-9956-ffa450edef68