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(jdbc): handle trigger in jdbc heartbeat/resubmit #2240

Merged
merged 8 commits into from
Oct 11, 2023

Conversation

Skraye
Copy link
Member

@Skraye Skraye commented Oct 5, 2023

This fix follow the JDBC heartbeat & task resubmit feature recently released in the 0.12

This pull request covers 3 big tasks:

  • Instead of deleting the workerJobRunning (that allows us to know which task was running on which worker) based on the taskRunId (which was only for the workerTaskRunning), we know use the key (avoiding duplicated data + handling workerTriggerRunning deletion).

  • WorkerTriggerRunning was not deleting correctly because they do not pass in the executor when they are successful, but in the Scheduler, as this feature is dedicated only to JDBC, a custom workerTriggerResultQueue was created to delete them only in JDBC.

  • Tests were not sufficient, so I've implemented 2 tests, one for triggers and one for tasks, where we execute a task/trigger, kill the workers, restart a new one and see if the task/trigger is correctly executed

@Skraye Skraye requested a review from tchiotludo October 5, 2023 21:36
@Skraye Skraye self-assigned this Oct 5, 2023
@Skraye Skraye force-pushed the fix/heartbeat-trigger-issue branch 4 times, most recently from 7c8dbf4 to e9c5d4e Compare October 9, 2023 14:13
@Skraye Skraye marked this pull request as ready for review October 9, 2023 14:14
@Skraye Skraye force-pushed the fix/heartbeat-trigger-issue branch 3 times, most recently from ad6fd5c to 2b52d4a Compare October 9, 2023 15:40
@Skraye Skraye force-pushed the fix/heartbeat-trigger-issue branch from c7136b2 to 88d66d2 Compare October 10, 2023 13:14
@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 8 Code Smells

43.3% 43.3% Coverage
14.2% 14.2% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@tchiotludo tchiotludo merged commit 9af6410 into develop Oct 11, 2023
@tchiotludo tchiotludo deleted the fix/heartbeat-trigger-issue branch October 11, 2023 08:41
tchiotludo pushed a commit that referenced this pull request Oct 11, 2023
This fix follow the JDBC heartbeat & task resubmit feature recently released in the 0.12
moadibfr pushed a commit that referenced this pull request Oct 31, 2023
This fix follow the JDBC heartbeat & task resubmit feature recently released in the 0.12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants