I want to put a local variable to user task by ‘api /task/{taskId}/variables’ with person object.
A person has 3 properties (name, age, address).
I create a custom ProcessEngineConfigurator implement from EngineConfigurator.
@Override
public void configure(AbstractEngineConfiguration engineConfiguration) {
SpringProcessEngineConfiguration appEngineConfiguration = (SpringProcessEngineConfiguration) engineConfiguration;
appEngineConfiguration.getVariableTypes().addType(new PersonVariableType(appEngineConfiguration.getMaxLengthString(),appEngineConfiguration.getObjectMapper()));
// Invoked after the initialisation of the engine. Think afterInit
}
I debug and check method .getVariableTypes() have PersonVariableType (my variable).
But When I test with post variable into user task then got error as follow:
“exception”: “Variable ‘person’ has unsupported type: ‘person’.”
My question. How to add custom variable type into flowable for easy parser to another tasks?