email connector exception

1
0
-1

Hi,

I see the following exception.
ps: i see this exception for activityInstanceId, processInstanceId, taskAssigneeId.

This is bonita 6.5. wonder if there is a work around for this

java.lang.reflect.InvocationTargetException
org.bonitasoft.engine.bpm.connector.ConnectorExecutionException: USERNAME=install | org.bonitasoft.engine.core.connector.exception.SConnectorException: org.bonitasoft.engine.expression.exception.SExpressionEvaluationException: Declared return type class java.lang.Long is not compatible with evaluated type class java.lang.Integer for expression activityInstanceId

and here's my code: activityInstanceId is a provided variable from Bonita ? I want to return all possible users for a task. Right now, I just hardcoded a userid.

`import org.bonitasoft.engine.identity.User;
import org.bonitasoft.engine.identity.ContactData;
import org.bonitasoft.engine.bpm.flownode.ActivityInstance;
import org.bonitasoft.engine.api.ProcessAPI;

ProcessAPI processAPI = apiAccessor.getProcessAPI();
List listUsers = processAPI.getPossibleUsersOfPendingHumanTask (activityInstanceId, 0, Integer.MAX_VALUE);

return BonitaUsers.getUserProfessionalContactInfo(apiAccessor,144).email`

EDIT: this happens only if you run 'Test' on the connector. If you just run the workflow, then no issues. I wasted plenty of time. hopefully helps someone

No answers yet.
Notifications