String commitTime = SVNTimeUtil.formatDate(new Date(System.currentTimeMillis())); myFSFS.setTransactionProperty(myTxn.getTxnId(), SVNRevisionProperty.DATE, commitTime);
    private long commit() throws SVNException {        long oldRev = myFSFS.getYoungestRevision();        if (myTxn.getBaseRevision() != oldRev) {            SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.FS_TXN_OUT_OF_DATE, "Transaction out of date");            SVNErrorManager.error(err);        }        verifyLocks();        String[] ids = myFSFS.getNextRevisionIDs();        String startNodeId = ids[0];        String startCopyId = ids[1];        long newRevision = oldRev + 1;        OutputStream protoFileOS = null;        FSID newRootId = null;        File revisionPrototypeFile = myTxnRoot.getTransactionRevFile();        long offset = revisionPrototypeFile.length();        try {            protoFileOS = SVNFileUtil.openFileForWriting(revisionPrototypeFile, true);            FSID rootId = FSID.createTxnId("0", "0", myTxn.getTxnId());            CountingStream revWriter = new CountingStream(protoFileOS, offset);            newRootId = myTxnRoot.writeFinalRevision(newRootId, revWriter, newRevision, rootId, startNodeId, startCopyId);            long changedPathOffset = myTxnRoot.writeFinalChangedPathInfo(revWriter);            String offsetsLine = "\n" + newRootId.getOffset() + " " + changedPathOffset + "\n";            protoFileOS.write(offsetsLine.getBytes("UTF-8"));        } catch (IOException ioe) {            SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.IO_ERROR, ioe.getLocalizedMessage());            SVNErrorManager.error(err, ioe);        } finally {            SVNFileUtil.closeFile(protoFileOS);        }        Map txnProps = myFSFS.getTransactionProperties(myTxn.getTxnId());        if (txnProps != null && !txnProps.isEmpty()) {            if (txnProps.get(SVNProperty.TXN_CHECK_OUT_OF_DATENESS) != null) {                myFSFS.setTransactionProperty(myTxn.getTxnId(), SVNProperty.TXN_CHECK_OUT_OF_DATENESS, null);            }            if (txnProps.get(SVNProperty.TXN_CHECK_LOCKS) != null) {                myFSFS.setTransactionProperty(myTxn.getTxnId(), SVNProperty.TXN_CHECK_LOCKS, null);            }        }        File dstRevFile = myFSFS.getNewRevisionFile(newRevision);        SVNFileUtil.rename(revisionPrototypeFile, dstRevFile);        File txnPropsFile = myFSFS.getTransactionPropertiesFile(myTxn.getTxnId());        File dstRevPropsFile = myFSFS.getNewRevisionPropertiesFile(newRevision);        SVNFileUtil.rename(txnPropsFile, dstRevPropsFile);        try {            myTxnRoot.writeFinalCurrentFile(newRevision, startNodeId, startCopyId);        } catch (IOException ioe) {            SVNErrorMessage err = SVNErrorMessage.create(SVNErrorCode.IO_ERROR, ioe.getLocalizedMessage());            SVNErrorManager.error(err, ioe);        }        purgeTxn();        return newRevision;    }