Temporal Cron Questions

Yes, if you have a running execution you could do something like:

// create new wf stub for existing exec
MyWorkflow workflow = client.newWorkflowStub(MyWorkflow.class, "<workflow_id>");
// convert to untyped
WorkflowStub untyped = WorkflowStub.fromTyped(workflow);
String cron = untyped.getOptions().get().getCronSchedule();

or use untyped stub directly

WorkflowStub stub = client.newUntypedWorkflowStub("<workflow_id>", Optional.empty(), Optional.empty());
stub.getOptions().get().getCronSchedule();
1 Like