Java SDK, Nexus OperationHandler + @UpdateMethod

Greetings. I’ve been experimenting with Nexus using the Java SDK. I can succesfully run operations to create/run workflows in a different namespace, but I can’t (yet?) figure out how to code the OperationHandler to call an update-method (@UpdateMethod). FYI: the Nexus Java examples only include the create workflow case.

Does anyone have an example?

Thank you!

Sean

Moving forward, the following works. However, what if the @UpdateMethod executes for > 10s. Is it possible to do an async equivalent?

@OperationImpl
public OperationHandler<
    ExpenseDbMosService.StageChangeRequest,
    ExpenseDbMosService.StageChangeResponse> stageChange() {

    return OperationHandler.sync(
        (ctx, details, input) ->
            Nexus.getOperationContext()
                .getWorkflowClient()
                .newWorkflowStub(
                    ExpenseDbProvisioningWorkflow.class,
                    input.getWorkflowId())
                .stageChange(input));
}

Not yet. The async version of the Update is going to be added.