Skip to content

Commit

Permalink
0006240: Failed to update a table_reload_request as processed for loadId
Browse files Browse the repository at this point in the history
  • Loading branch information
erilong committed Feb 12, 2024
1 parent 09958ff commit 3fed693
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1068,6 +1068,11 @@ public Map<Integer, ExtractRequest> insertReloadEvents(Node targetNode, boolean
transaction.prepareAndExecute(getSql("updateTableReloadStatusFinalizeCount"), finalizeBatchCount, new Date(), loadId);
int rowsAffected = transaction.prepareAndExecute(getSql("updateProcessedTableReloadRequest"), new Date(), loadId);
if (rowsAffected == 0) {
List<TableReloadRequest> requests = transaction.query(getSql("selectTableReloadRequestsByLoadId"),
new TableReloadRequestMapper(), new Object[] { loadId }, new int[] { symmetricDialect.getSqlTypeForIds() });
if (requests != null && requests.size() > 0 && requests.get(0).isProcessed()) {
throw new InterruptedException("Table reload request appears to be cancelled");
}
throw new SymmetricException(String.format("Failed to update a table_reload_request as processed for loadId '%s' ",
loadId));
}
Expand Down Expand Up @@ -1095,7 +1100,7 @@ public Map<Integer, ExtractRequest> insertReloadEvents(Node targetNode, boolean
} else if (ex instanceof RuntimeException) {
throw (RuntimeException) ex;
} else if (ex instanceof InterruptedException) {
log.info("Insert reload events was interrupted");
log.info("Insert reload events was interrupted: {}", ex.getMessage() == null ? "" : ex.getMessage());
}
} finally {
close(transaction);
Expand Down Expand Up @@ -3261,7 +3266,7 @@ public String findNodeIdsByNodeGroupId() {

protected void checkInterrupted() throws InterruptedException {
if (Thread.interrupted()) {
throw new InterruptedException();
throw new InterruptedException("Thread received interrupt");
}
}

Expand Down

0 comments on commit 3fed693

Please sign in to comment.