[GOBBLIN-1440] move 'cancel trigger code' from job catalog to job monitor #3277
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Dear Gobblin maintainers,
Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
JIRA
Description
Currently Add/update/delete of flow specs and cancellation of a job execution happen via putting/deleting these specs in job catalog. Listeners of Spec Catalog take appropriate actions. While for add/update/delete this makes sense to modify job catalog, it makes little sense for job execution cancellation request to update job catalog in order to trigger the cancellation because job and execution are two different entities.
This PR will move cancel-job-triggering logic from job catalog listeners to kafkajob monitor. This will also clean a lot of code which exists due to the need to pass cancellation request from job monitor to job catalog to spec consumer to jobConfigurationManager to jobScheduler
Tests
manually tested
Commits