Inject a Request Handler for all HTTP Tasks

Hello,

My core requirement is to add a dynamic security token (from a ThreadLocal) to all outgoing HTTP Service Tasks.

Currently, I can achieve this by defining an <flowable:httpRequestHandler> in every single BPMN file, but I want to avoid this manual step. I’ve already tried providing a custom, @Primary HttpClientConfig bean to add an interceptor, but my custom configuration is never actually used by the engine at runtime.

Is there a different, recommended way to programmatically inject this request handler logic for all HTTP tasks without modifying the BPMN XML? I’m open to any approach, like a specific EngineConfigurationConfigurer hook or replacing a different default behaviour.

Thanks for your help!

1 Like

yes,

regards

Martin