use of com.enonic.xp.repo.impl.dump.serializer.json.CommitDumpEntryJson in project xp by enonic.
the class CommitDumpUpgrader method createCommit.
private void createCommit(final RepositoryId repositoryId) {
tmpDumpWriter.openCommitsMeta(repositoryId);
try {
final NodeCommitEntry nodeCommitEntry = NodeCommitEntry.create().build();
commitId = new NodeCommitId().toString();
final CommitDumpEntryJson commitDumpEntryJson = CommitDumpEntryJson.create().commitId(commitId).message("Dump upgrade").committer(nodeCommitEntry.getCommitter().toString()).timestamp(nodeCommitEntry.getTimestamp().toString()).build();
final byte[] commitDumpEntrySerialized = serialize(commitDumpEntryJson);
tmpDumpWriter.storeTarEntry(commitDumpEntrySerialized, commitId + ".json");
} finally {
tmpDumpWriter.closeMeta();
}
}
Aggregations