Source:
<code>private void processBatch(Context context) throws SQLException, IOException, InterruptedException { if (currentBatchValues.size() == 0) return; context.getCounter(PhoenixScrutinyJobCounters.BATCHES_PROCESSED_COUNT).increment(1); String inClause = QueryUtil.constructParameterizedInClause(numTargetPkCols, currentBatchValues.size()); String indexQuery = targetTableQuery + inClause; try (PreparedStatement targetStatement = connection.prepareStatement(indexQuery)) { Map<String, Pair<Long, List<Object>>> targetPkToSourceValues = buildTargetStatement(targetStatement); if (isTest) { <START> ScrutinyTestClock clock = new ScrutinyTestClock(3600000); <END> EnvironmentEdgeManager.injectEdge(clock); } queryTargetTable(context, targetStatement, targetPkToSourceValues); checkIfInvalidRowsExpired(context, targetPkToSourceValues); context.getCounter(PhoenixScrutinyJobCounters.INVALID_ROW_COUNT) .increment(targetPkToSourceValues.size()); if (outputInvalidRows) { for (Pair<Long, List<Object>> sourceRowWithoutTargetRow : targetPkToSourceValues.values()) { List<Object> valuesWithoutTarget = sourceRowWithoutTargetRow.getSecond(); if (OutputFormat.FILE.equals(outputFormat)) { context.write( new Text(Arrays.toString(valuesWithoutTarget.toArray())), new Text("Target row not found")); } else if (OutputFormat.TABLE.equals(outputFormat)) { writeToOutputTable(context, valuesWithoutTarget, null, sourceRowWithoutTargetRow.getFirst(), -1L); } } } if (outputInvalidRows && OutputFormat.TABLE.equals(outputFormat)) { outputUpsertStmt.executeBatch(); outputConn.commit(); } currentBatchValues.clear(); } }</code><technical_language>isTest guarantee TTL is 360000? Perhpas a const is in test creates table this TTL</technical_language>

Target:
protected void processBatch(Context context) throws SQLException, IOException, InterruptedException { if (currentBatchValues.size() == 0) return; context.getCounter(PhoenixScrutinyJobCounters.BATCHES_PROCESSED_COUNT).increment(1); String inClause = QueryUtil.constructParameterizedInClause(numTargetPkCols, currentBatchValues.size()); String indexQuery = targetTableQuery + inClause; try (PreparedStatement targetStatement = connection.prepareStatement(indexQuery)) { Map<String, Pair<Long, List<Object>>> targetPkToSourceValues = buildTargetStatement(targetStatement); preQueryTargetTable(); queryTargetTable(context, targetStatement, targetPkToSourceValues); checkIfInvalidRowsExpired(context, targetPkToSourceValues); context.getCounter(PhoenixScrutinyJobCounters.INVALID_ROW_COUNT) .increment(targetPkToSourceValues.size()); if (outputInvalidRows) { for (Pair<Long, List<Object>> sourceRowWithoutTargetRow : targetPkToSourceValues.values()) { List<Object> valuesWithoutTarget = sourceRowWithoutTargetRow.getSecond(); if (OutputFormat.FILE.equals(outputFormat)) { context.write( new Text(Arrays.toString(valuesWithoutTarget.toArray())), new Text("Target row not found")); } else if (OutputFormat.TABLE.equals(outputFormat)) { writeToOutputTable(context, valuesWithoutTarget, null, sourceRowWithoutTargetRow.getFirst(), -1L); } } } if (outputInvalidRows && OutputFormat.TABLE.equals(outputFormat)) { outputUpsertStmt.executeBatch(); outputConn.commit(); } currentBatchValues.clear(); } }