style: cargo fmt fixup for 1.9 feature edits
This commit is contained in:
@@ -15,8 +15,7 @@ pub trait WorkflowRepository: Send + Sync {
|
|||||||
) -> crate::Result<()>;
|
) -> crate::Result<()>;
|
||||||
async fn get_runnable_instances(&self, as_at: DateTime<Utc>) -> crate::Result<Vec<String>>;
|
async fn get_runnable_instances(&self, as_at: DateTime<Utc>) -> crate::Result<Vec<String>>;
|
||||||
async fn get_workflow_instance(&self, id: &str) -> crate::Result<WorkflowInstance>;
|
async fn get_workflow_instance(&self, id: &str) -> crate::Result<WorkflowInstance>;
|
||||||
async fn get_workflow_instance_by_name(&self, name: &str)
|
async fn get_workflow_instance_by_name(&self, name: &str) -> crate::Result<WorkflowInstance>;
|
||||||
-> crate::Result<WorkflowInstance>;
|
|
||||||
async fn get_workflow_instances(&self, ids: &[String]) -> crate::Result<Vec<WorkflowInstance>>;
|
async fn get_workflow_instances(&self, ids: &[String]) -> crate::Result<Vec<WorkflowInstance>>;
|
||||||
|
|
||||||
/// Atomically allocate the next sequence number for a given workflow
|
/// Atomically allocate the next sequence number for a given workflow
|
||||||
|
|||||||
@@ -58,10 +58,7 @@ impl HostContext for HostContextImpl {
|
|||||||
// child shows up as `{definition_id}-{N}` in lookups and logs.
|
// child shows up as `{definition_id}-{N}` in lookups and logs.
|
||||||
// Sub-workflows always use the default; callers wanting a custom
|
// Sub-workflows always use the default; callers wanting a custom
|
||||||
// name should start the parent workflow directly.
|
// name should start the parent workflow directly.
|
||||||
let n = self
|
let n = self.persistence.next_definition_sequence(&def_id).await?;
|
||||||
.persistence
|
|
||||||
.next_definition_sequence(&def_id)
|
|
||||||
.await?;
|
|
||||||
instance.name = format!("{def_id}-{n}");
|
instance.name = format!("{def_id}-{n}");
|
||||||
|
|
||||||
let id = self.persistence.create_new_workflow(&instance).await?;
|
let id = self.persistence.create_new_workflow(&instance).await?;
|
||||||
|
|||||||
@@ -65,10 +65,7 @@ pub async fn run(
|
|||||||
.collect();
|
.collect();
|
||||||
println!(
|
println!(
|
||||||
"{}",
|
"{}",
|
||||||
render_table(
|
render_table(&["Name", "ID", "Version", "Steps", "Description"], &rows)
|
||||||
&["Name", "ID", "Version", "Steps", "Description"],
|
|
||||||
&rows
|
|
||||||
)
|
|
||||||
);
|
);
|
||||||
println!("{} definition(s)", resp.definitions.len());
|
println!("{} definition(s)", resp.definitions.len());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -131,9 +131,8 @@ async fn dispatch(
|
|||||||
Command::Watch(args) => watch::run(args, client).await,
|
Command::Watch(args) => watch::run(args, client).await,
|
||||||
Command::Logs(args) => logs::run(args, client).await,
|
Command::Logs(args) => logs::run(args, client).await,
|
||||||
Command::SearchLogs(args) => search_logs::run(args, client, format).await,
|
Command::SearchLogs(args) => search_logs::run(args, client, format).await,
|
||||||
Command::Login(_)
|
Command::Login(_) | Command::Logout(_) | Command::Whoami(_) | Command::Validate(_) => {
|
||||||
| Command::Logout(_)
|
unreachable!()
|
||||||
| Command::Whoami(_)
|
}
|
||||||
| Command::Validate(_) => unreachable!(),
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user