CreateMatchingPollWorkflowTaskQueueResponse create response for matching's PollWorkflowTaskQueue
(historyResponse *historyservice.RecordWorkflowTaskStartedResponse, workflowExecution *commonpb.WorkflowExecution, token []byte)
| 526 | |
| 527 | // CreateMatchingPollWorkflowTaskQueueResponse create response for matching's PollWorkflowTaskQueue |
| 528 | func CreateMatchingPollWorkflowTaskQueueResponse(historyResponse *historyservice.RecordWorkflowTaskStartedResponse, workflowExecution *commonpb.WorkflowExecution, token []byte) *matchingservice.PollWorkflowTaskQueueResponseWithRawHistory { |
| 529 | matchingResp := &matchingservice.PollWorkflowTaskQueueResponseWithRawHistory{ |
| 530 | TaskToken: token, |
| 531 | WorkflowExecution: workflowExecution, |
| 532 | WorkflowType: historyResponse.WorkflowType, |
| 533 | PreviousStartedEventId: historyResponse.PreviousStartedEventId, |
| 534 | StartedEventId: historyResponse.StartedEventId, |
| 535 | Attempt: historyResponse.GetAttempt(), |
| 536 | NextEventId: historyResponse.NextEventId, |
| 537 | StickyExecutionEnabled: historyResponse.StickyExecutionEnabled, |
| 538 | TransientWorkflowTask: historyResponse.TransientWorkflowTask, |
| 539 | WorkflowExecutionTaskQueue: historyResponse.WorkflowExecutionTaskQueue, |
| 540 | BranchToken: historyResponse.BranchToken, |
| 541 | ScheduledTime: historyResponse.ScheduledTime, |
| 542 | StartedTime: historyResponse.StartedTime, |
| 543 | Queries: historyResponse.Queries, |
| 544 | Messages: historyResponse.Messages, |
| 545 | History: historyResponse.History, |
| 546 | NextPageToken: historyResponse.NextPageToken, |
| 547 | RawHistory: historyResponse.RawHistoryBytes, |
| 548 | } |
| 549 | |
| 550 | return matchingResp |
| 551 | } |
| 552 | |
| 553 | // CreateHistoryStartWorkflowRequest create a start workflow request for history. |
| 554 | // Assumes startRequest is valid. See frontend workflow_handler for detailed validation logic. |
no test coverage detected