I have a Controller:
@RestController
@RequestMapping("processes")
public class ProcessController {
@Autowired
private ProcessEngine processEngine;
@Autowired
private RepositoryService repositoryService;
@GetMapping
public List<ProcessDefinition> listProcess() {
return processEngine.getRepositoryService().createProcessDefinitionQuery().list();
}
@PostMapping(consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
public Deployment addProcess(@RequestPart MultipartFile file) throws IOException {
return repositoryService.createDeployment().addInputStream(file.getOriginalFilename(), file.getInputStream()).deploy();
}
}
And I have already upload the test.bpmn20.xml
with the addProcess()
method, but when I want to get ProcessDefinition list with the listProcess
method, the console warning:
Resolved [org.springframework.http.converter.HttpMessageNotWritableException: Could not write JSON: Cannot invoke "org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.getIdentityLinkServiceConfiguration()" because "processEngineConfiguration" is null; nested exception is com.fasterxml.jackson.databind.JsonMappingException: Cannot invoke "org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.getIdentityLinkServiceConfiguration()" because "processEngineConfiguration" is null (through reference chain: java.util.ArrayList[0]->org.flowable.engine.impl.persistence.entity.ProcessDefinitionEntityImpl["identityLinks"])]
My POM.xml:
<dependency>
<groupId>org.flowable</groupId>
<artifactId>flowable-spring-boot-starter</artifactId>
<version>6.7.2</version>
</dependency>
Why console warning this? What can I do?
Pls help me, thx!