Source:
public void runForRejoin(SiteProcedureConnection siteConnection, TaskLog m_taskLog) throws IOException { if (m_commaSeparatedNameOfViewsToPause == null) { StringBuilder commaSeparatedViewNames = new StringBuilder(); Database db = VoltDB.instance().getCatalogContext().database; for (Table table : VoltDB.instance().getCatalogContext().tables) { if (CatalogUtil.isSnapshotablePersistentTableView(db, table)) { commaSeparatedViewNames.append(table.getTypeName()).append(","); } } if (commaSeparatedViewNames.length() > 0) { commaSeparatedViewNames.setLength(commaSeparatedViewNames.length() - 1); } m_commaSeparatedNameOfViewsToPause = commaSeparatedViewNames.toString(); siteConnection.setViewsEnabled(m_commaSeparatedNameOfViewsToPause, false); } if (!m_schemaHasNoTables) { boolean sourcesReady = false; RestoreWork rejoinWork = m_rejoinSiteProcessor.poll(m_snapshotBufferAllocator); if (rejoinWork != null) { restoreBlock(rejoinWork, siteConnection); sourcesReady = true; } if (m_rejoinSiteProcessor.isEOF() == false) { returnToTaskQueue(sourcesReady); } else { if (REJOINLOG.isDebugEnabled()) { REJOINLOG.debug(m_whoami + "Rejoin snapshot transfer is finished"); } m_rejoinSiteProcessor.close(); boolean allSitesFinishStreaming; if (m_streamSnapshotMb != null) { VoltDB.instance().getHostMessenger().removeMailbox(m_streamSnapshotMb.getHSId()); m_streamSnapshotMb = null; allSitesFinishStreaming = s_streamingSiteCount.decrementAndGet() == 0; } else { int pendingSites = s_streamingSiteCount.get(); assert(pendingSites >= 0); allSitesFinishStreaming = pendingSites == 0; } if (allSitesFinishStreaming) { doFinishingTask(siteConnection); } } } else { doFinishingTask(siteConnection); m_snapshotCompletionMonitor.set(null); } }

Target:
public void runForRejoin(SiteProcedureConnection siteConnection, TaskLog m_taskLog) throws IOException { if (m_commaSeparatedNameOfViewsToPause == null) { StringBuilder commaSeparatedViewNames = new StringBuilder(); Database db = VoltDB.instance().getCatalogContext().database; for (Table table : VoltDB.instance().getCatalogContext().tables) { if (CatalogUtil.isSnapshotablePersistentTableView(db, table)) { commaSeparatedViewNames.append(table.getTypeName()).append(","); } } if (commaSeparatedViewNames.length() > 0) { commaSeparatedViewNames.setLength(commaSeparatedViewNames.length() - 1); } m_commaSeparatedNameOfViewsToPause = commaSeparatedViewNames.toString(); siteConnection.setViewsEnabled(m_commaSeparatedNameOfViewsToPause, false); } if (!m_schemaHasNoTables) { boolean sourcesReady = false; RestoreWork rejoinWork = m_rejoinSiteProcessor.poll(m_snapshotBufferAllocator); if (rejoinWork != null) { restoreBlock(rejoinWork, siteConnection); sourcesReady = true; } if (m_rejoinSiteProcessor.isEOF() == false) { returnToTaskQueue(sourcesReady); } else { if (REJOINLOG.isDebugEnabled()) { REJOINLOG.debug(m_whoami + "Rejoin snapshot transfer is finished"); } m_rejoinSiteProcessor.close(); boolean allSitesFinishStreaming; if (m_streamSnapshotMb != null) { VoltDB.instance().getHostMessenger().removeMailbox(m_streamSnapshotMb.getHSId()); m_streamSnapshotMb = null; allSitesFinishStreaming = s_streamingSiteCount.decrementAndGet() == 0; } else { int pendingSites = s_streamingSiteCount.get(); assert(pendingSites >= 0); allSitesFinishStreaming = pendingSites == 0; } if (allSitesFinishStreaming) { doFinishingTask(siteConnection); } else { returnToTaskQueue(sourcesReady); } } } else { doFinishingTask(siteConnection); m_snapshotCompletionMonitor.set(null); } }