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
Workflow: no longer require DB connection string (#1570)
* Workflow: no longer require DB connection string
PR updates the workflow clients to use the Dapr RPCs to list Workflow
instance IDs instead of connecting directly to the database. This
removes the requirement that the Dapr CLI need both connectivity to the
database and a connection string, greatly improving the user experience.
`$ dapr workflow list` now works out-of-the-box without any additional
configuration.
Connection strings are still supported via the `--connection-string`
flag for users using Dapr pre v1.17.
Also exposes the `--force` flag on `$ dapr workflow purge` to allow
purging without a worker connected.
Signed-off-by: joshvanl <me@joshvanl.dev>
* Cleanup workflow history output
Signed-off-by: joshvanl <me@joshvanl.dev>
* Improve parent details
Signed-off-by: joshvanl <me@joshvanl.dev>
* result -> output
Signed-off-by: joshvanl <me@joshvanl.dev>
* Adds input/output to child workflow history
Signed-off-by: joshvanl <me@joshvanl.dev>
* Adds eventId to SubOrchestrationCompleted details ouput
Signed-off-by: joshvanl <me@joshvanl.dev>
---------
Signed-off-by: joshvanl <me@joshvanl.dev>
Copy file name to clipboardExpand all lines: cmd/workflow/purge.go
+5-1Lines changed: 5 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -25,12 +25,14 @@ var (
25
25
flagPurgeOlderThanstring
26
26
flagPurgeAllbool
27
27
flagPurgeConn*connFlag
28
+
flagPurgeForcebool
28
29
schedulerNamespacestring
29
30
)
30
31
31
32
varPurgeCmd=&cobra.Command{
32
33
Use: "purge",
33
-
Short: "Purge one or more workflow instances with a terminal state. Accepts a workflow instance ID argument or flags to purge multiple/all terminal instances. Also deletes all associated scheduler jobs.",
34
+
Short: "Purge workflow instances with a terminal state.",
35
+
Long: "Purge one or more workflow instances with a terminal state. Accepts a workflow instance ID argument or flags to purge multiple/all terminal instances. Also deletes all associated scheduler jobs.",
PurgeCmd.Flags().StringVar(&flagPurgeOlderThan, "all-older-than", "", "Purge workflow instances older than the specified Go duration or timestamp, e.g., '24h' or '2023-01-02T15:04:05Z'.")
81
84
PurgeCmd.Flags().BoolVar(&flagPurgeAll, "all", false, "Purge all workflow instances in a terminal state. Use with caution.")
PurgeCmd.Flags().BoolVar(&flagPurgeForce, "force", false, "force will force a purge of a workflow, regardless of its current runtime state, or whether an active worker can process it, the backend will attempt to delete it anyway. This necessarily means the purging is executed out side of the workflow state machine, and therefore, can lead to corrupt state or broken workflow execution. Usage of this should _only_ be used when you know the workflow is not being currently processed. It is highly recommended to avoid using this flag unless absolutely necessary.")
83
87
84
88
PurgeCmd.Flags().StringVar(&schedulerNamespace, "scheduler-namespace", "dapr-system", "Kubernetes namespace where the scheduler is deployed, only relevant if --kubernetes is set")
Copy file name to clipboardExpand all lines: cmd/workflow/rerun.go
+2-1Lines changed: 2 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,8 @@ var (
32
32
33
33
varReRunCmd=&cobra.Command{
34
34
Use: "rerun [instance ID]",
35
-
Short: "ReRun a workflow instance from the beginning or a specific event. Optionally, a new instance ID and input to the starting event can be provided.",
35
+
Short: "Re-run a workflow instance.",
36
+
Long: "ReRun a workflow instance from the beginning or a specific event. Optionally, a new instance ID and input to the starting event can be provided.",
cmd.Flags().StringVarP(&flagConnectionString, "connection-string", "c", "", "The connection string used to connect and authenticate to the actor state store")
208
+
cmd.Flags().StringVarP(&flagConnectionString, "connection-string", "c", "", "Only used for Dapr runtime versions 1.16. The connection string used to connect and authenticate to the actor state store")
209
209
cmd.Flags().StringVarP(&flagTableName, "table-name", "t", "", "The name of the table or collection which is used as the actor state store")
0 commit comments