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

Run ScheduledTasks during processing #10355

Merged
merged 2 commits into from
Sep 15, 2022
Merged

Conversation

Zelldon
Copy link
Member

@Zelldon Zelldon commented Sep 14, 2022

Description

Removes the guarantee that scheduled Tasks are only executed after commit and only if no inProcessing is going on. This is not necessary, since all actions we want to execute after a commit are executed via PostcommitTasks which are added to the ProcessingResult.

See related comment and discussion #9723 (comment)

Future improvements:

  • We can create our own actor for the SchedulingService this would decouple better than scheduling and processing
  • We can remove the multiple scheduling in the SchedulingService Remove the additional submit #10291

Related issues

closes #9723
related #10272

Definition of Done

Not all items need to be done depending on the issue and the pull request.

Code changes:

  • The changes are backwards compatibility with previous versions
  • If it fixes a bug then PRs are created to backport the fix to the last two minor versions. You can trigger a backport by assigning labels (e.g. backport stable/1.3) to the PR, in case that fails you need to create backports manually.

Testing:

  • There are unit/integration tests that verify all acceptance criterias of the issue
  • New tests are written to ensure backwards compatibility with further versions
  • The behavior is tested manually
  • The change has been verified by a QA run
  • The impact of the changes is verified by a benchmark

Documentation:

  • The documentation is updated (e.g. BPMN reference, configuration, examples, get-started guides, etc.)
  • New content is added to the release announcement
  • If the PR changes how BPMN processes are validated (e.g. support new BPMN element) then the Camunda modeling team should be informed to adjust the BPMN linting.

Please refer to our review guidelines.

Previously we avoid to run scheduled tasks if currently a processing was going on.
This is not really necessary and have potential negative impacts of tasks,
which are then delayed unnecessarily. For example it might happen that tasks are
delayed until no new record was committed on the log (worst case), which might
introduce a huge delay to timers and other things which have been scheduled.

All necessary task we want to run during processing AFTER a commit are executed
as PostCommitTasks, which means we no longer need thus gurantee
@github-actions
Copy link
Contributor

Test Results

   859 files  ±  0     859 suites  ±0   1h 37m 23s ⏱️ +4s
6 603 tests +90  6 592 ✔️ +90  11 💤 ±0  0 ±0 
6 787 runs  +90  6 776 ✔️ +90  11 💤 ±0  0 ±0 

Results for commit 77a6c30. ± Comparison against base commit 15c1814.

Copy link
Member

@saig0 saig0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Zelldon looks good from my side 👍

@Zelldon
Copy link
Member Author

Zelldon commented Sep 15, 2022

bors r+

@zeebe-bors-camunda
Copy link
Contributor

Build succeeded:

@zeebe-bors-camunda zeebe-bors-camunda bot merged commit 93cfe32 into main Sep 15, 2022
@zeebe-bors-camunda zeebe-bors-camunda bot deleted the zell-run-inprocessing branch September 15, 2022 07:50
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.

Iterate over Side effects
2 participants