Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
| id: 'workflow-pause-success-toast', | ||
| message: translate('workflows.pause-success'), | ||
| }); | ||
| } catch (err: unknown) { |
There was a problem hiding this comment.
⚠️ Type 'string | undefined' is not assignable to type 'string'.
| $refresh = Date.now(); | ||
| triggerRefresh(Action.Reset); | ||
| hideResetModal(); | ||
| } catch (err) { |
There was a problem hiding this comment.
⚠️ Type 'string | undefined' is not assignable to type 'string'.
| ) => { | ||
| if (refresh && !pause && $workflowRun?.workflow?.isRunning) { | ||
| const shouldFetch = | ||
| refresh.timestamp && |
There was a problem hiding this comment.
⚠️ 'refresh.action' is possibly 'null'.
| response.workflowExecutionInfo.status, | ||
| ); | ||
| const isRunning = status === 'Running'; | ||
| const isPaused = status === 'Paused'; |
There was a problem hiding this comment.
⚠️ 'response' is possibly 'undefined'.⚠️ 'response.workflowExecutionInfo' is possibly 'undefined'.
| ); | ||
| const isRunning = status === 'Running'; | ||
| const isPaused = status === 'Paused'; | ||
| const historyEvents = response.workflowExecutionInfo.historyLength; |
There was a problem hiding this comment.
⚠️ 'response' is possibly 'undefined'.⚠️ 'response.workflowExecutionInfo' is possibly 'undefined'.
| parent, | ||
| stateTransitionCount, | ||
| isRunning, | ||
| isPaused, |
There was a problem hiding this comment.
⚠️ Type 'Duration | undefined' is not assignable to type 'Duration'.
fdf8e6c to
1d394d2
Compare
| @@ -127,6 +137,7 @@ | |||
| <div class="xl:hidden"> | |||
| <WorkflowActions | |||
There was a problem hiding this comment.
⚠️ Type 'boolean | undefined' is not assignable to type 'boolean'.
| @@ -127,6 +137,7 @@ | |||
| <div class="xl:hidden"> | |||
| <WorkflowActions | |||
| {isRunning} | |||
There was a problem hiding this comment.
⚠️ Type 'boolean | undefined' is not assignable to type 'boolean'.
| <WorkflowActions | ||
| {isRunning} | ||
| {isPaused} | ||
| {cancelInProgress} |
There was a problem hiding this comment.
⚠️ Type 'WorkflowExecution | null' is not assignable to type 'WorkflowExecution'.
| @@ -154,6 +165,7 @@ | |||
| <div class="max-xl:hidden"> | |||
| <WorkflowActions | |||
There was a problem hiding this comment.
⚠️ Type 'boolean | undefined' is not assignable to type 'boolean'.
| @@ -154,6 +165,7 @@ | |||
| <div class="max-xl:hidden"> | |||
| <WorkflowActions | |||
| {isRunning} | |||
There was a problem hiding this comment.
⚠️ Type 'boolean | undefined' is not assignable to type 'boolean'.
| <WorkflowActions | ||
| {isRunning} | ||
| {isPaused} | ||
| {cancelInProgress} |
There was a problem hiding this comment.
⚠️ Type 'WorkflowExecution | null' is not assignable to type 'WorkflowExecution'.
| unhandledAction(action); | ||
| } | ||
|
|
||
| return translate('workflows.workflow-action-reason-placeholder', { |
There was a problem hiding this comment.
⚠️ Variable 'translatedAction' is used before being assigned.
| workflowPauseEnabled(page.data.settings, $coreUser, namespace), | ||
| ); | ||
| const pauseEnabled = $derived( | ||
| !!page.data.namespace.namespaceInfo?.capabilities?.workflowPause, |
There was a problem hiding this comment.
Is this an action we want to make configurable here ⬇️ ?
ui/server/server/config/config.go
Lines 55 to 60 in 023f034
There was a problem hiding this comment.
Yes I think we want an env to disable
e92dd60 to
a435f61
Compare
|
Small thing but we should probably change the pause icon for "Freeze". Not a blocker but it might be confusing have Pause Workflow and a pause icon below it |
|
|
||
| const getOnlyWorkflowWithPendingActivities = async ( | ||
| refresh: number, | ||
| refresh: RefreshAction, |
There was a problem hiding this comment.
Small thing but we should probably change the pause icon for "Freeze". Not a blocker but it might be confusing have Pause Workflow and a pause icon below it
@Alex-Tideman check out #3137.
|
here are the steps i followed to test this: Testing Workflow Pause FeatureTo test this PR locally, you need to enable the workflow pause feature flag on your Temporal server: Setup Steps
Verification You can verify the feature is enabled by checking the namespace capabilities: Should return: "workflowPause": true |
andrewzamojc
left a comment
There was a problem hiding this comment.
Neat! I was able to pause a workflow locally. Code looks good 👍
Auto-generated version bump from 2.45.0 to 2.45.1 Specific version: 2.45.1 Changes included: - [`f71743b5`](f71743b) Nav icons fix/kt (#3127) - [`68f18987`](68f1898) Refresh token POC (#2966) - [`36b26a9f`](36b26a9) fix: prevent 'No Workers Running' flash during workflow load (#3131) - [`b4d224ee`](b4d224e) Auto refresh UI update (#3137) - [`3ca9d3c3`](3ca9d3c) Revert "Refresh token POC (#2966)" (#3139) - [`73e45caa`](73e45ca) Workflow Pause (#3114)
Auto-generated version bump from 2.45.0 to 2.45.1 Specific version: 2.45.1 Changes included: - [`f71743b5`](f71743b) Nav icons fix/kt (#3127) - [`68f18987`](68f1898) Refresh token POC (#2966) - [`36b26a9f`](36b26a9) fix: prevent 'No Workers Running' flash during workflow load (#3131) - [`b4d224ee`](b4d224e) Auto refresh UI update (#3137) - [`3ca9d3c3`](3ca9d3c) Revert "Refresh token POC (#2966)" (#3139) - [`73e45caa`](73e45ca) Workflow Pause (#3114) Co-authored-by: laurakwhit <15069288+laurakwhit@users.noreply.github.com>
Description & motivation 💭
Screenshots (if applicable) 📸
Design Considerations 🎨
Testing 🧪
How was this tested 👻
Steps for others to test: 🚶🏽♂️🚶🏽♀️
Run temporal server from a local build
truemake binsandmake starttemporal operator namespace create --namespace canarycanarynamespace, runtemporal operator search-attribute create --namespace canary --name CustomKeywordField --type KeywordRun the UI against a local build of temporal server
workflow-pausebranch in the UI repocd server/ && make buildcd .. && pnpm dev:local-temporalRun some sample workflows in the canary-go repo
make binsand./temporal-canary startWith disableWriteActions enabled
Pause Workflowis not visibleWith
namespaceInfo>capabilities>workflowPauseset to false > go to aRunningworkflowPause Workflowis not visibleWith
namespaceInfo>capabilities>workflowPauseset to true > go to aRunningworkflowPause Workflowis disabledPause Workflow> enter a reason and confirmPausedand button switches toUnpause WorkflowSelect
Unpause Workflow> enter a reason and confirmChecklists
Draft Checklist
Merge Checklist
Issue(s) closed
DT-3566Docs
Any docs updates needed?