add bulk putAll method to ObjectDatabase and optimize RevTreeBuilder.normalize() to use it and write less stale trees