Start note: I have little experience with Java and am new with Spring Boot and Camunda 7.
I am trying to make a Spring Boot (v2.6.7) backend system which handles the business logic of the whole application and embed Camunda (v7.17.0) to handle the specific path for the process that an application goes through.
To make an application the frontend sends an HTTP request to Spring Boot which starts an instance in the process. The instance id gets saved in the MySQL database by Spring Boot to be able to link the data of an application with the instance created in Camunda, and in the process the applicationId in MySQL will also be put in the camunda forms by Spring Boot.
I was wondering how Spring Boot can tell Camunda to complete a task while (sometimes) providing extra data required in the camunda form at the task. Since Camunda is embedded this shouldn’t go through REST.
And how should I model it in the Camunda Modeler? Currently I have put user tasks on all tasks which Spring Boot should ‘manually’ trigger.
At this moment I have made an HTTP request in Spring Boot from which a process is started by calling it in RuntimeService. (I start it from a message start event since I have multiple)
ProcessInstance instance = runtimeService.startProcessInstanceByMessage("fieldManagerStart");
I save the instanceId from this ProcessInstance in MySQL. The next step I want to take is complete the next task for which I have to provide an id which I have saved in the Application entity in the database. How can I do this?
EDIT: Another question, are you able to get the name of the task the instance is currently at? I would like to show the current task (and perhaps the history) in my own ReactJS frontend.