Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: always set task_data via JdbcCustomization method #495

Merged
merged 2 commits into from
May 30, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,8 @@ public Instant replace(Execution toBeReplaced, SchedulableInstance newInstance)
ps.setInt(index++, 0); // consecutive_failures
jdbcCustomization.setInstant(ps, index++, newExecutionTime); // execution_time
// may cause datbase-specific problems, might have to use setNull instead
ps.setObject(index++, serializer.serialize(newData)); // task_data
jdbcCustomization.setTaskData(
ps, index++, serializer.serialize(newData)); // task_data
ps.setString(index++, toBeReplaced.taskInstance.getTaskName()); // task_name
ps.setString(index++, toBeReplaced.taskInstance.getId()); // task_instance
ps.setLong(index++, toBeReplaced.version); // version
Expand Down Expand Up @@ -485,7 +486,7 @@ private boolean rescheduleInternal(
if (newData != null) {
// may cause datbase-specific problems, might have to use setNull instead
// FIXLATER: optionally support bypassing serializer if byte[] already
ps.setObject(index++, serializer.serialize(newData.data));
jdbcCustomization.setTaskData(ps, index++, serializer.serialize(newData.data));
}
ps.setString(index++, execution.taskInstance.getTaskName());
ps.setString(index++, execution.taskInstance.getId());
Expand Down
Loading