Skip to content

Scope Workflow Stores to Workflow ID - #16523

Merged
mvdbeek merged 3 commits into
galaxyproject:devfrom
ElectronicBlueberry:workflow-store-scope
Aug 8, 2023
Merged

Scope Workflow Stores to Workflow ID#16523
mvdbeek merged 3 commits into
galaxyproject:devfrom
ElectronicBlueberry:workflow-store-scope

Conversation

@ElectronicBlueberry

Copy link
Copy Markdown
Member

Changes the workflow stores to be scoped, in preparation for enabling to use multiple instances of the workflow editor simultaneously.

Relevant comment: #16510 (comment)

How to test the changes?

(Select all options that apply)

  • I've included appropriate automated tests.
  • This is a refactoring of components with existing test coverage.
  • Instructions for manual testing are as follows:
    1. [add testing steps and prerequisites here if you didn't write automated tests covering all your changes]

License

  • I agree to license these and all my past contributions to the core galaxy codebase under the MIT license.

@github-actions github-actions Bot added this to the 23.2 milestone Aug 7, 2023
@ElectronicBlueberry ElectronicBlueberry added area/UI-UX kind/refactoring cleanup or refactoring of existing code, no functional changes labels Aug 7, 2023
throw new Error("WorkflowId is undefined");
}

return defineStore(`workflowConnectionStore${workflowId}`, {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nice solution! Is this documented somewhere as a pattern for scoping stores ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I found the concept here: vuejs/pinia#840 (comment)
Seems to work very well.

@mvdbeek mvdbeek left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Very cool, thank you!

@mvdbeek
mvdbeek merged commit 65970c6 into galaxyproject:dev Aug 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/UI-UX kind/refactoring cleanup or refactoring of existing code, no functional changes

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants