How to dynamically create models, deploy processes, launch instances and not require any stored bpmn files

The current workflow I understand is this: the workflow must first design a model, design one *.bpmn file through Camunda Modeler, then call REST API or Java SDK to call the relevant interface for deployment , and start an instance based on the deployed workflow, then a workflow instance is implemented.

But this process needs to store the bpmn file, and my boss will not use camunda modeler (of course he doesn’t need to design it by hand), I want my boss to have any workflow requirement every time, I can create the model, deploy it and start the instance dynamically via sdk without designing the bpmn file and storing it, is it possible to achieve this goal?

I looked at some of the official documentation, but I found that the examples require the model stream to be persistent.

Create a Model

I don’t need to store it, I want to use it up and destroy it, reuse it and dynamically build it again without incurring any storage costs.Is this idea realistic?

Hello @BigNight ,

this should be doable. If I get you correct, you want to have ad-hoc workflows?

As the process engine is able to undeploy models, you could create a mechanism that undeploys a model after the process instance is complete.

How would you imagine creating a model that is no bpmn file? Would it still be bpmn? Or would it be something else, like an abstraction layer on top of bpmn?

Jonathan

1 Like

Hi @BigNight,

another thought on top of Jonathans:

This sounds strange, because processes are repeatable.

If you are talking about simple tasks, there is an api to create user tasks independent of any process model: TaskService (Camunda Platform Javadocs 7.19.9-ee), it’s available as REST API, too: Camunda Platform REST API

Hope this helps, Ingo

2 Likes