Reflect durabletask-protobuf#29: update submodule and regenerate protos#67
Reflect durabletask-protobuf#29: update submodule and regenerate protos#67
Conversation
…mpatibility
- Rename WorkflowState -> BackendWorkflowState in backend_service.pb.go
- Rename OrchestratorMessage -> WorkflowMessage in backend_service.pb.go
- Rename OrchestrationMetadata -> WorkflowMetadata in backend_service.pb.go
- Rename CompleteOrchestrationWorkItem{Request,Response} -> CompleteWorkflowWorkItem{Request,Response}
- Rename AbandonOrchestrationWorkItem{Request,Response} -> AbandonWorkflowWorkItem{Request,Response}
- Rename GetOrchestrationRuntimeState{Request,Response} -> GetWorkflowRuntimeState{Request,Response}
- Rename OrchestratorWorkItems -> WorkflowWorkItems in BackendMetrics
- Rename OrchestrationRuntimeState{Message} -> WorkflowRuntimeState{Message} in runtime_state.pb.go
- Create workflow_aliases.go with type aliases for new workflow-centric names and
backward-compatible aliases for old orchestration-centric names
- Add new gRPC methods: CompleteWorkflowTask, AbandonTaskWorkflowWorkItem in orchestrator service
- Add new gRPC methods: GetWorkflowRuntimeState, CompleteWorkflowWorkItem, AbandonWorkflowWorkItem
in backend service
- Update package prefix in backend_service_grpc.pb.go from durabletask.protos.backend.v1 to
durabletask.protos.v1
- Update backend/backend.go type aliases to use new renamed types and add new workflow aliases
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…omments - Update backend/backend.go to use protos.WorkflowMetadata, protos.WorkflowRuntimeState, and protos.WorkflowRuntimeStateMessage directly instead of alias chains - Fix stale comments in runtime_state.pb.go to reference workflow terminology Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: JoshVanL <15893072+JoshVanL@users.noreply.github.com>
JoshVanL
left a comment
There was a problem hiding this comment.
Update the protos to use that PR and update the codebase accordingly
The protobuf files have been regenerated with types renamed from
Orchestration*/Orchestrator* to Workflow*. This commit:
1. Rewrites api/protos/workflow_aliases.go to provide backward-compatible
type aliases for old Orchestration* names pointing to the new Workflow*
real types (reversing the previous direction of aliases).
2. Updates all call sites across the codebase to use the new field/method
names introduced by the regenerated .pb.go files:
- OrchestrationInstance → WorkflowInstance (field)
- OrchestrationStatus → WorkflowStatus (field)
- OrchestrationState → WorkflowState (field in responses)
- OrchestrationIdReusePolicy → WorkflowIdReusePolicy (field)
- GetOrchestratorStarted() → GetWorkflowExecutorStarted()
- GetOrchestratorCompleted() → GetWorkflowExecutorCompleted()
- GetSubOrchestrationInstance*() → GetSubWorkflowInstance*()
- GetCompleteOrchestration() → GetCompleteWorkflow()
- GetCreateSubOrchestration() → GetCreateSubWorkflow()
- GetTerminateOrchestration() → GetTerminateWorkflow()
- GetOrchestratorVersionNotAvailable() → GetWorkflowVersionNotAvailable()
- OrchestratorActionType → WorkflowActionType (struct field)
- OrchestrationStatus_name/value → WorkflowStatus_name/value
- WorkflowSpanID field (was OrchestrationSpanID)
- Struct literal oneof field names updated (e.g. CompleteOrchestration →
CompleteWorkflow, CreateSubOrchestration → CreateSubWorkflow, etc.)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…protos Co-authored-by: JoshVanL <15893072+JoshVanL@users.noreply.github.com>
Done in commit Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Mirrors the changes from dapr/durabletask-protobuf#29 by updating the protobuf submodule to that PR's branch and regenerating all Go proto files from the actual new proto definitions, then updating the codebase accordingly.
Submodule
submodules/durabletask-protobufupdated to commit0d06f73on branchcopilot/rename-protos-to-workflow.gitmodulesupdated to track that branchRegenerated proto files
The old monolithic
orchestrator_service.protois split into focused files. Old generated files removed:orchestrator_service.pb.goorchestrator_service_grpc.pb.goNew generated files added:
workflow_messages.pb.go—WorkflowInstance,WorkflowStatus,WorkflowState,WorkflowVersion,WorkflowIdReusePolicy, core shared typeshistory_events.pb.go— allHistoryEventvariants,SubWorkflowInstance*Event,WorkflowExecutorStartedEventworkflow_actions.pb.go—WorkflowAction,WorkflowRequest,WorkflowResponse, action typesentity_messages.pb.go— entity operation messagesworkflow_service.pb.go+workflow_service_grpc.pb.go—TaskHubSidecarServiceRegenerated with new type names:
backend_service.pb.go/backend_service_grpc.pb.go—WorkflowMessage,WorkflowMetadata,CompleteWorkflowWorkItem*,AbandonWorkflowWorkItem*,GetWorkflowRuntimeState*,BackendWorkflowState, newWorkflow*-named RPCs alongside deprecatedOrchestration*ones; RPC path prefix updated todurabletask.protos.v1runtime_state.pb.go—WorkflowRuntimeState,WorkflowRuntimeStateMessageBackward-compatible aliases (
workflow_aliases.go)Rewritten to map old
Orchestration*/Orchestrator*names to the new canonicalWorkflow*types now defined in the generated code:Codebase updates
All non-generated source and test files updated to use new field/method names from the regenerated protos:
es.OrchestrationInstance→es.WorkflowInstancee.GetOrchestratorStarted()→e.GetWorkflowExecutorStarted()e.GetSubOrchestrationInstance*()→e.GetSubWorkflowInstance*()resp.OrchestrationState→resp.WorkflowStatestate.OrchestrationStatusfield →state.WorkflowStatusWorkflowAction_CompleteWorkflow,WorkflowAction_CreateSubWorkflow, etc.)dapr/dapr compatibility
Backward-compat aliases ensure existing
dapr/daprcode continues to compile unchanged:backend.OrchestrationMetadata,backend.OrchestrationRuntimeState,protos.OrchestratorRequest/Response,protos.OrchestrationInstance,protos.OrchestrationVersion,runtimestate.NewOrchestrationRuntimeState(), etc. all remain valid.✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.