You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add experimental warning around activity batch operations (#966)
## What was changed
Add experimental warning around pause/update-options/unpause/reset
activity by type or use of --query flag with activity operations.
## Why?
These have been experimental commands and should have been marked
experimental from the beginning.
## Checklist
1. Closes NA
2. How was this tested: manually built and verified
3. Any docs updates needed?
f.StringVarP(&v.WorkflowId, "workflow-id", "w", "", "Workflow ID. You must set either --workflow-id or --query.")
168
+
f.StringVarP(&v.Query, "query", "q", "", "Content for an SQL-like `QUERY` List Filter. You must set either --workflow-id or --query. Note: Using --query for batch activity operations is an experimental feature and may change in the future.")
169
+
f.StringVarP(&v.RunId, "run-id", "r", "", "Run ID. Only use with --workflow-id. Cannot use with --query.")
170
+
f.StringVar(&v.Reason, "reason", "", "Reason for batch operation. Only use with --query. Defaults to user name.")
171
+
f.BoolVarP(&v.Yes, "yes", "y", false, "Don't prompt to confirm signaling. Only allowed when --query is present.")
172
+
f.Float32Var(&v.Rps, "rps", 0, "Limit batch's requests per second. Only allowed if query is present.")
173
+
f.StringArrayVar(&v.Headers, "headers", nil, "Temporal workflow headers in 'KEY=VALUE' format. Keys must be identifiers, and values must be JSON values. May be passed multiple times to set multiple Temporal headers. Note: These are workflow headers, not gRPC headers.")
s.Command.Flags().StringVarP(&s.ActivityId, "activity-id", "a", "", "The Activity ID to reset. Mutually exclusive with `--query`, `--match-all`, and `--activity-type`. Requires `--workflow-id` to be specified.")
535
-
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will be reset. Mutually exclusive with `--match-all` and `activity-id`.")
557
+
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will be reset. Mutually exclusive with `--match-all` and `activity-id`. Note: Resetting Activity by Type is an experimental feature and may change in the future.")
536
558
s.Command.Flags().BoolVar(&s.KeepPaused, "keep-paused", false, "If the activity was paused, it will stay paused.")
537
559
s.Command.Flags().BoolVar(&s.ResetAttempts, "reset-attempts", false, "Reset the activity attempts.")
538
560
s.Command.Flags().BoolVar(&s.ResetHeartbeats, "reset-heartbeats", false, "Reset the Activity's heartbeats. Only works with --reset-attempts.")
539
-
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every activity should be reset. Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`.")
561
+
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every activity should be reset. Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`. Note: This is an experimental feature and may change in the future.")
540
562
s.Jitter=0
541
563
s.Command.Flags().Var(&s.Jitter, "jitter", "The activity will reset at random a time within the specified duration. Can only be used with --query.")
542
564
s.Command.Flags().BoolVar(&s.RestoreOriginalOptions, "restore-original-options", false, "Restore the original options of the activity.")
s.Command.Flags().StringVarP(&s.ActivityId, "activity-id", "a", "", "The Activity ID to unpause. Mutually exclusive with `--query`, `--match-all`, and `--activity-type`. Requires `--workflow-id` to be specified.")
577
-
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will unpause. Can only be used without --match-all. Either `activity-id` or `activity-type` must be provided, but not both.")
599
+
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will unpause. Can only be used without --match-all. Either `activity-id` or `activity-type` must be provided, but not both. Note: Unpausing Activity by Type is an experimental feature and may change in the future.")
578
600
s.Command.Flags().BoolVar(&s.ResetAttempts, "reset-attempts", false, "Reset the activity attempts.")
579
601
s.Command.Flags().BoolVar(&s.ResetHeartbeats, "reset-heartbeats", false, "Reset the Activity's heartbeats. Only works with --reset-attempts.")
580
-
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every paused activity should be unpaused. This flag is ignored if activity-type is provided.")
602
+
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every paused activity should be unpaused. This flag is ignored if activity-type is provided. Note: This is an experimental feature and may change in the future.")
581
603
s.Jitter=0
582
604
s.Command.Flags().Var(&s.Jitter, "jitter", "The activity will start at random a time within the specified duration. Can only be used with --query.")
s.Command.Flags().StringVarP(&s.ActivityId, "activity-id", "a", "", "The Activity ID to update options. Mutually exclusive with `--query`, `--match-all`, and `--activity-type`. Requires `--workflow-id` to be specified.")
624
-
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will be updated. Mutually exclusive with `--match-all` and `activity-id`.")
625
-
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`.")
646
+
s.Command.Flags().StringVar(&s.ActivityType, "activity-type", "", "Activities of this Type will be updated. Mutually exclusive with `--match-all` and `activity-id`. Note: Updating Activity options by Type is an experimental feature and may change in the future.")
647
+
s.Command.Flags().BoolVar(&s.MatchAll, "match-all", false, "Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`. Note: This is an experimental feature and may change in the future.")
626
648
s.Command.Flags().StringVar(&s.TaskQueue, "task-queue", "", "Name of the task queue for the Activity.")
627
649
s.ScheduleToCloseTimeout=0
628
650
s.Command.Flags().Var(&s.ScheduleToCloseTimeout, "schedule-to-close-timeout", "Indicates how long the caller is willing to wait for an activity completion. Limits how long retries will be attempted.")
s.Command.Flags().Float32Var(&s.RetryBackoffCoefficient, "retry-backoff-coefficient", 0, "Coefficient used to calculate the next retry interval. The next retry interval is previous interval multiplied by the backoff coefficient. Must be 1 or larger.")
640
662
s.Command.Flags().IntVar(&s.RetryMaximumAttempts, "retry-maximum-attempts", 0, "Maximum number of attempts. When exceeded the retries stop even if not expired yet. Setting this value to 1 disables retries. Setting this value to 0 means unlimited attempts(up to the timeouts).")
641
663
s.Command.Flags().BoolVar(&s.RestoreOriginalOptions, "restore-original-options", false, "Restore the original options of the activity.")
Copy file name to clipboardExpand all lines: internal/temporalcli/commands.yaml
+61-4Lines changed: 61 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -278,10 +278,12 @@ commands:
278
278
type: string
279
279
description: |
280
280
Activities of this Type will be updated. Mutually exclusive with `--match-all` and `activity-id`.
281
+
Note: Updating Activity options by Type is an experimental feature and may change in the future.
281
282
- name: match-all
282
283
type: bool
283
284
description: |
284
285
Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`.
286
+
Note: This is an experimental feature and may change in the future.
285
287
- name: task-queue
286
288
type: string
287
289
description: Name of the task queue for the Activity.
@@ -338,7 +340,7 @@ commands:
338
340
type: bool
339
341
description: Restore the original options of the activity.
340
342
option-sets:
341
-
- single-workflow-or-batch
343
+
- single-activity-or-batch
342
344
343
345
- name: temporal activity pause
344
346
summary: Pause an Activity
@@ -429,6 +431,7 @@ commands:
429
431
type: string
430
432
description: |
431
433
Activities of this Type will unpause. Can only be used without --match-all. Either `activity-id` or `activity-type` must be provided, but not both.
434
+
Note: Unpausing Activity by Type is an experimental feature and may change in the future.
432
435
- name: reset-attempts
433
436
type: bool
434
437
description: Reset the activity attempts.
@@ -440,13 +443,14 @@ commands:
440
443
type: bool
441
444
description: |
442
445
Every paused activity should be unpaused. This flag is ignored if activity-type is provided.
446
+
Note: This is an experimental feature and may change in the future.
443
447
- name: jitter
444
448
type: duration
445
449
description: |
446
450
The activity will start at random a time within the specified duration.
447
451
Can only be used with --query.
448
452
option-sets:
449
-
- single-workflow-or-batch
453
+
- single-activity-or-batch
450
454
451
455
- name: temporal activity reset
452
456
summary: Reset an Activity
@@ -506,7 +510,9 @@ commands:
506
510
description: The Activity ID to reset. Mutually exclusive with `--query`, `--match-all`, and `--activity-type`. Requires `--workflow-id` to be specified.
507
511
- name: activity-type
508
512
type: string
509
-
description: Activities of this Type will be reset. Mutually exclusive with `--match-all` and `activity-id`.
513
+
description: |
514
+
Activities of this Type will be reset. Mutually exclusive with `--match-all` and `activity-id`.
515
+
Note: Resetting Activity by Type is an experimental feature and may change in the future.
510
516
- name: keep-paused
511
517
type: bool
512
518
description: If the activity was paused, it will stay paused.
@@ -521,6 +527,7 @@ commands:
521
527
type: bool
522
528
description: |
523
529
Every activity should be reset. Every activity should be updated. Mutually exclusive with `--activity-id` and `--activity-type`.
530
+
Note: This is an experimental feature and may change in the future.
524
531
- name: jitter
525
532
type: duration
526
533
description: |
@@ -531,7 +538,7 @@ commands:
531
538
description: |
532
539
Restore the original options of the activity.
533
540
option-sets:
534
-
- single-workflow-or-batch
541
+
- single-activity-or-batch
535
542
536
543
- name: temporal batch
537
544
summary: Manage running batch jobs
@@ -4441,6 +4448,56 @@ option-sets:
4441
4448
description: Build ID for a Worker Deployment.
4442
4449
required: true
4443
4450
4451
+
# Duplicate of single-workflow-or-batch with an experimental note on --query.
4452
+
# Cannot extend the shared option set because workflow commands that also use
4453
+
# it (workflow cancel, workflow count, etc.) are not experimental.
4454
+
- name: single-activity-or-batch
4455
+
options:
4456
+
- name: workflow-id
4457
+
type: string
4458
+
short: w
4459
+
description: |
4460
+
Workflow ID.
4461
+
You must set either --workflow-id or --query.
4462
+
- name: query
4463
+
type: string
4464
+
short: q
4465
+
description: |
4466
+
Content for an SQL-like `QUERY` List Filter.
4467
+
You must set either --workflow-id or --query.
4468
+
Note: Using --query for batch activity operations is an experimental feature and may change in the future.
4469
+
- name: run-id
4470
+
type: string
4471
+
short: r
4472
+
description: |
4473
+
Run ID.
4474
+
Only use with --workflow-id.
4475
+
Cannot use with --query.
4476
+
- name: reason
4477
+
type: string
4478
+
description: |
4479
+
Reason for batch operation.
4480
+
Only use with --query.
4481
+
Defaults to user name.
4482
+
- name: yes
4483
+
type: bool
4484
+
short: y
4485
+
description: |
4486
+
Don't prompt to confirm signaling.
4487
+
Only allowed when --query is present.
4488
+
- name: rps
4489
+
type: float
4490
+
description: |
4491
+
Limit batch's requests per second.
4492
+
Only allowed if query is present.
4493
+
- name: headers
4494
+
type: string[]
4495
+
description: |
4496
+
Temporal workflow headers in 'KEY=VALUE' format.
4497
+
Keys must be identifiers, and values must be JSON values.
4498
+
May be passed multiple times to set multiple Temporal headers.
4499
+
Note: These are workflow headers, not gRPC headers.
0 commit comments