@Autowire doesnt work in java delegate spring boot

Hi

I am having a strange problem.

From a java delegate class I am calling an class by using @Autowired. This works fine when i use another class in the same java application, but in the class that implements JavaDelegate, it turns out as null.

Grateful for any hint.

Br

Frank

Take a look at Depending on how the JavaDelegate class is included in the bpmn file a Spring Bean is instantiated or not

1 Like

Hi

Ok, so when I add the delegate class in BPMN modeller, I should use “${GetCaseworkDelegate}” instead of no.path.structure.etCaseworkDelegate?

Br

Frank

Well you need to use the delegate expression implantation rather than “class”. And you would be using the bean name (which I believe is default to lowercase first letter) so it would be getCaseWorkDelegate assuming that’s the name of your class

1 Like

@StephenOTT

Is there a documentation on how to use delegate expression instead of the java delegate object?

Frank

There is just the link I posted above and the link that is posted in the thread