@@ -371,38 +371,42 @@ public void cancelWorkflow(String workflowId) {
371371 * step are copied over
372372 *
373373 * @param workflowId Original workflow Id
374+ * @param forkedWorkflowId Id of the new workflow
374375 * @param startStep Start execution from this step. Prior steps copied over
375376 * @param applicationVersion The version of the application to run
376377 * @return handle to the workflow
377378 */
378- public WorkflowHandle <?> forkWorkflow (String workflowId , int startStep , String applicationVersion ) {
379- return this .dbosExecutor .forkWorkflow (workflowId , startStep , applicationVersion ) ;
379+ public WorkflowHandle <?> forkWorkflow (String workflowId , String forkedWorkflowId , int startStep , String applicationVersion ) {
380+ return this .dbosExecutor .forkWorkflow (workflowId , forkedWorkflowId , startStep , applicationVersion ) ;
380381 }
381382
382383 /**
383- *
384384 * Fork the workflow. Re-execute with another Id from the step provided. Steps prior to the provided
385385 * step are copied over
386386 *
387387 * @param workflowId Original workflow Id
388388 * @param startStep Start execution from this step. Prior steps copied over
389+ * @param applicationVersion The version of the application to run
389390 * @return handle to the workflow
390391 */
391-
392- public WorkflowHandle <?> forkWorkflow (String workflowId , int startStep ) {
393- return this .dbosExecutor .forkWorkflow (workflowId , startStep , null ) ;
392+ public WorkflowHandle <?> forkWorkflow (String workflowId , int startStep , String applicationVersion ) {
393+ return this .dbosExecutor .forkWorkflow (workflowId , null , startStep , applicationVersion ) ;
394394 }
395395
396396 /**
397- * Rerun this workflow from the start with another generated workflow Id
398397 *
399- * @param workflowId Original workflow id
398+ * Fork the workflow. Re-execute with another Id from the step provided. Steps prior to the provided
399+ * step are copied over
400+ *
401+ * @param workflowId Original workflow Id
402+ * @param startStep Start execution from this step. Prior steps copied over
400403 * @return handle to the workflow
401404 */
402405
403- public WorkflowHandle <?> restartWorkflow (String workflowId ) {
404- return this .dbosExecutor .forkWorkflow (workflowId , 0 , null ) ;
406+ public WorkflowHandle <?> forkWorkflow (String workflowId , int startStep ) {
407+ return this .dbosExecutor .forkWorkflow (workflowId , null , startStep , null ) ;
405408 }
406409
410+
407411}
408412
0 commit comments