Hi
We are creating a process programatically, out-of-the box by using the bonita REST API via the bonita-client available in:
<bonita.bpm.version>7.0.0</bonita.bpm.version> .. <dependency> <groupId>org.bonitasoft.engine</groupId> <artifactId>bonita-client</artifactId> <version>${bonita.bpm.version}</version> </dependency>
We are able to create and deploy a simple process (and execute it via the bonita portal). However now we are trying to programatically create a service task with a REST connector call. To to it, we use:
ConnectorDefinitionBuilder connectorBuilder = automatctask.addConnector("CallRestDATA", "rest-get", "1.0.0", ConnectorEvent.ON_ENTER); connectorBuilder.ignoreError();
However we always get an error, and in bonita portal we can see the following message:
The Process cannot be enabled. Connectors must be resolved before enabling the Process.
Intuitively, we have tried to instantiate a ConnectorDescriptor but we don’t know to link with the task. We couldn’t find in the documentation any example. Do you have any hint?
Thanks in advance.