OAK-805 - Support for existing Jackrabbit 2.x DataStores

Minor change. Using ByteStream util to skip inputstream and proper closing of InputStreams

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