-
Notifications
You must be signed in to change notification settings - Fork 0
feat(workflow): add workflow data update methods and caching #855
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
Conversation
- Added UpdateWorkflowData and UpdateWorkflowDataStruct methods to OperationHelper - Cached WorkflowService instance in OperationHelperDefault - Added MergeStruct method to WorkflowOptions for struct merging - Simplified WithWorkflowStructData option using new MergeStruct - Improved workflow metadata handling in WorkflowCoordinator - Fixed metadata byte handling in workflow service
WalkthroughThe changes introduce new methods to update workflow data using either maps or structs across the Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant OperationHelper
participant WorkflowService
participant WorkflowCoordinator
participant RequestDB
Client->>OperationHelper: UpdateWorkflowData(requestID, data)
OperationHelper->>WorkflowService: UpdateWorkflowData(ctx, requestID, data)
WorkflowService->>WorkflowCoordinator: UpdateWorkflowData(ctx, requestID, data)
WorkflowCoordinator->>RequestDB: Retrieve and update request metadata
RequestDB-->>WorkflowCoordinator: Success/Failure
WorkflowCoordinator-->>WorkflowService: Result
WorkflowService-->>OperationHelper: Result
OperationHelper-->>Client: Result
sequenceDiagram
participant Client
participant OperationHelper
participant WorkflowService
Client->>OperationHelper: UpdateWorkflowDataStruct(requestID, structData)
OperationHelper->>WorkflowService: UpdateWorkflowDataStruct(ctx, requestID, structData, tag)
WorkflowService->>WorkflowCoordinator: UpdateWorkflowDataStruct(ctx, requestID, structData, tag)
WorkflowCoordinator->>RequestDB: Retrieve, merge, update metadata
RequestDB-->>WorkflowCoordinator: Success/Failure
WorkflowCoordinator-->>WorkflowService: Result
WorkflowService-->>OperationHelper: Result
OperationHelper-->>Client: Result
Possibly related PRs
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (3)
🧰 Additional context used🧬 Code Graph Analysis (1)core/workflow.go (2)
🔇 Additional comments (12)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Summary by CodeRabbit
New Features
Refactor