DBObject index = new BasicDBObject();
index.put(MongoCommit.KEY_REVISION_ID, 1L);
index.put(MongoCommit.KEY_BRANCH_ID, 1L);
DBObject options = new BasicDBObject();
options.put("unique", Boolean.TRUE);
commitCollection.ensureIndex(index, options);
MongoCommit commit = new MongoCommit();
commit.setAffectedPaths(Collections.singleton("/"));
commit.setBaseRevisionId(0L);
commit.setDiff(INITIAL_COMMIT_DIFF);
commit.setMessage(INITIAL_COMMIT_MESSAGE);