Map<String, ObjectId> resolved = new HashMap<String, ObjectId>();
for (String path : r.keySet()) {
MergeResult<? extends Sequence> p = r.get(path);
TemporaryBuffer buf = new TemporaryBuffer.LocalFile(10 * 1024 * 1024);
try {
fmt.formatMerge(buf, p, "BASE", oursName, theirsName, "UTF-8");
buf.close();
InputStream in = buf.openInputStream();
try {
resolved.put(path, ins.insert(Constants.OBJ_BLOB, buf.length(), in));