/** * Compacts the named indices found on this journal as of the most recent * commit point, writing their view onto a new Journal. This method MAY be * used concurrently with the {@link Journal} but writes after the selected * commit point WILL NOT be reflected in the output file. Typical uses are * to reduce the space required by the backing store, to improve locality in * the backing store, and to make a backup of the most recent commit point. * * @param outFile * The file on which the new journal will be created. * * @return The {@link Future} on which you must {@link Future#get() wait} * for the {@link CompactTask} to complete. The already open journal * is accessible using {@link Future#get()}. If you are backing up * data, then be sure to shutdown the returned {@link Journal} so * that it can release its resources. */ public Future<Journal> compact(final File outFile) { return executorService.submit(new CompactTask(this, outFile, getLastCommitTime())); }
/** * Compacts the named indices found on this journal as of the most recent * commit point, writing their view onto a new Journal. This method MAY be * used concurrently with the {@link Journal} but writes after the selected * commit point WILL NOT be reflected in the output file. Typical uses are * to reduce the space required by the backing store, to improve locality in * the backing store, and to make a backup of the most recent commit point. * * @param outFile * The file on which the new journal will be created. * * @return The {@link Future} on which you must {@link Future#get() wait} * for the {@link CompactTask} to complete. The already open journal * is accessible using {@link Future#get()}. If you are backing up * data, then be sure to shutdown the returned {@link Journal} so * that it can release its resources. */ public Future<Journal> compact(final File outFile) { return executorService.submit(new CompactTask(this, outFile, getLastCommitTime())); }
protected InnerJournalTransactionService() { super(checkProperties(properties), Journal.this); final long lastCommitTime = Journal.this.getLastCommitTime(); if (lastCommitTime != 0L) { /* * Notify the transaction service on startup so it can set the * effective release time based on the last commit time for the * store. * * Note: For HA, the releaseTime is updated by the consensus * protocol once a quorum is met. Before the quorum meets (and * before a service joins with a met quorum) each service will * track its own releaseTime. Therefore, during startup, the * quorum will be null or HAStatusEnum will be NotReady so the * TXS will automatically track the release time until the * service joins with a met quorum. */ if (log.isInfoEnabled()) log.info("Startup: lastCommitTime=" + lastCommitTime); updateReleaseTimeForBareCommit(lastCommitTime); } }
protected InnerJournalTransactionService() { super(checkProperties(properties), Journal.this); final long lastCommitTime = Journal.this.getLastCommitTime(); if (lastCommitTime != 0L) { /* * Notify the transaction service on startup so it can set the * effective release time based on the last commit time for the * store. * * Note: For HA, the releaseTime is updated by the consensus * protocol once a quorum is met. Before the quorum meets (and * before a service joins with a met quorum) each service will * track its own releaseTime. Therefore, during startup, the * quorum will be null or HAStatusEnum will be NotReady so the * TXS will automatically track the release time until the * service joins with a met quorum. */ if (log.isInfoEnabled()) log.info("Startup: lastCommitTime=" + lastCommitTime); updateReleaseTimeForBareCommit(lastCommitTime); } }
@Override protected IGraphAccessor newGraphAccessor() { final BigdataOptionData opt = getOptionData(); /* * Use a read-only view (sampling depends on access to the BTree rather * than the ReadCommittedIndex). */ final BigdataGraphAccessor graphAccessor = new BigdataGraphAccessor( opt.jnl, opt.namespace, opt.jnl.getLastCommitTime()); return graphAccessor; }
@Override protected IGraphAccessor newGraphAccessor() { final BigdataOptionData opt = getOptionData(); /* * Use a read-only view (sampling depends on access to the BTree rather * than the ReadCommittedIndex). */ final BigdataGraphAccessor graphAccessor = new BigdataGraphAccessor( opt.jnl, opt.namespace, opt.jnl.getLastCommitTime()); return graphAccessor; }
if (commitTime > src.getLastCommitTime())
private void dumpGlobalRowStore(final PrintWriter out) { .getLastCommitTime());
if (commitTime > src.getLastCommitTime())
private void dumpGlobalRowStore(final PrintWriter out) { .getLastCommitTime());
+ ", nindices=" + sourceJournal.getName2Addr( sourceJournal.getLastCommitTime()).rangeCount());
+ ", nindices=" + sourceJournal.getName2Addr( sourceJournal.getLastCommitTime()).rangeCount());
namespace, TimestampUtility.asHistoricalRead(j1 .getLastCommitTime())); namespace, TimestampUtility.asHistoricalRead(j2 .getLastCommitTime()));
namespace, TimestampUtility.asHistoricalRead(j1 .getLastCommitTime())); namespace, TimestampUtility.asHistoricalRead(j2 .getLastCommitTime()));
System.err.println("lastCommitTime="+journal.getLastCommitTime());
System.err.println("lastCommitTime="+journal.getLastCommitTime());
assertTrue(Math.abs(tx1) >= journal.getLastCommitTime()); assertTrue(Math.abs(tx1) >= journal.getLastCommitTime());
assertTrue(Math.abs(tx1) >= journal.getLastCommitTime()); assertTrue(Math.abs(tx1) >= journal.getLastCommitTime());
final long start = journal.getLastCommitTime();
final long start = journal.getLastCommitTime();