BusinessProcessScoped beans designed usage? (CDI)

as per: Contextual Programming Model | docs.camunda.org

As per the description of the bean, it is basically a serializable object that gets saved to DB as a Process Variable.

Was the intended design to be used within Java Delegates?

Hi @StephenOTT,

from the example it seems that this style can be used in your business layer to access the process engine, but not in Java Delegates.

I remember that some developers were good with writing 10 annotations over a two-line-method and hide the logic from the reader. Not my coding style …

Hope this helps, Ingo

@Ingo_Richtsmeier I am not sure i understand your response.
The BusinessProcessScoped is a bean and defined in the docs as:

Instances of BusinessProcessScoped beans are stored as process variables in the current process instance.

Hi @StephenOTT,

I haven’t use these beans in my developer career, just saw some presentations about it.

I think that they were used in the heavy weight, old fashioned Java EE programming to access data in java server pages.

You can use the same classes, not as beans, in your Java Delegates as well.

It would look like:

BusinessTripRequest request = (BusinessTripRequest) execution.getVariable("businessTripRequest");

Hope this helps, Ingo

Thanks. yes they were JEE.