OAK-1760 - RepositoryUpgrade leads to one large commit with DocumentNodeStore causing OOM

Temporary approach which uses different copying code path depending on type of NodeStore. This would be reverted post merge to 1.0

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