Skip to content

Commit

Permalink
IWF-438: Add workflow with finalized RPC method
Browse files Browse the repository at this point in the history
  • Loading branch information
lwolczynski committed Dec 30, 2024
1 parent e484f61 commit c210761
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions src/test/java/io/iworkflow/integ/rpc/RpcWorkflowWithFinalRpc.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
package io.iworkflow.integ.rpc;

import io.iworkflow.core.Context;
import io.iworkflow.core.ObjectWorkflow;
import io.iworkflow.core.RPC;
import io.iworkflow.core.StateDef;
import io.iworkflow.core.communication.Communication;
import io.iworkflow.core.persistence.Persistence;
import org.springframework.stereotype.Component;

import java.util.Arrays;
import java.util.List;

@Component
public class RpcWorkflowWithFinalRpc implements ObjectWorkflow {

@Override
public List<StateDef> getWorkflowStates() {
return Arrays.asList(
StateDef.startingState(new RpcWorkflowState1()),
StateDef.nonStartingState(new RpcWorkflowState2())
);
}

@RPC
public final void testRpc(Context context, String input, Persistence persistence, Communication communication) {
return;
}
}

0 comments on commit c210761

Please sign in to comment.