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 background activity completion #5882

Merged
merged 4 commits into from
Aug 10, 2024

Conversation

sfmskywalker
Copy link
Member

@sfmskywalker sfmskywalker commented Aug 10, 2024

Fixed background activity completion by fixing a bug in the bookmark updater.
The bookmark updater was deleting too many bookmarks, preventing background activities from being resumed & completed.


This change is Reviewable

Added debug logging in `BookmarkResumer` and `StoreBookmarkQueue` to track workflow resumptions and queue additions. Updated `ICommitStateHandler` to include `WorkflowState` parameter and modified related implementations. Adjusted logging configuration in sample app and removed unused service import.
This change ensures that the `RootType` property is set to `AgentActivity` inside the `AgentActivityProvider`. It enhances the descriptor's metadata, enabling clearer classification and potentially improving integration with other components.
Modified RemoveBookmarksAsync to filter bookmarks by BookmarkIds rather than Hashes for improved accuracy. Updated filter creation logic to accommodate the new identifier field.
Add workflowState as an argument to commitStateHandler.CommitAsync. This ensures that the commitStateHandler has the necessary context to commit properly and maintains consistency in workflow state changes.
@sfmskywalker sfmskywalker merged commit 6741db3 into main Aug 10, 2024
5 of 7 checks passed
@sfmskywalker sfmskywalker deleted the bug/background-activity-completion branch August 10, 2024 08:41
fanslead pushed a commit to fanslead/elsa-core that referenced this pull request Aug 14, 2024
…core into feature/catchflow

* 'feature/catchflow' of https://github.com/fanslead/elsa-core: (200 commits)
  [Fix] Replace "bundles" with "apps" in the content of README.md to align with current source code structure. (elsa-workflows#5885)
  Rename Model to ServiceProfile across the codebase.
  Add TenantId to workflow definition and skip multitenancy test
  Fix background activity completion (elsa-workflows#5882)
  Update persistence feature base classes to include self-type
  Refactor journal data access and improve byte[] handling (elsa-workflows#5878)
  Changed RegisterClassMap to TryRegisterClassMap on SerializedKeyValuePair classmap registration (elsa-workflows#5877)
  Add Orchard Core Integration + Agents Module (elsa-workflows#5871)
  Add customizable DB exception handlers
  Refactor workflow execution and pipeline handling
  Update elsa-v3-avatar.png
  Add new Elsa v3 avatar to design and update README
  Add MyEvent activity to Elsa services
  Add TODO
  Fix logger type
  Update ElsaStudioVersion to 3.2.0-rc4.473
  Fix incorrect serializer reference
  Update pre-release version in GitHub Actions workflow
  Rework Workflow Context Feature (elsa-workflows#5861)
  Add engine exception handling middleware
  ...
@JulienAmbos
Copy link

@sfmskywalker Thank you for merging this fix. But is this already released? I think it did not make it into 3.2.0?
This might fix my issue with mass transit scheduled background activities not being completed, when inside a Parallel as the last activity (except Finish()) in a workflow.

@sfmskywalker
Copy link
Member Author

Hi @JulienAmbos , this merge commit went into the main branch, which means it will be part of 3.3.0 (and is currently part of the 3.3.0-preview builds available from the feedz.io feed. If possible, you can try it out against your project, but keep in mind that the 3.3 previews can be volatile until it’s released later this year.

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.

2 participants