Timeout on synchronous Service Task

I have standard ServiceTask (not async), which makes http requests, but after 20 minutes, even if all requests are done, I’m getting error that current Transaction was already rolled back. Is there any way to set this timeout somehow in activiti?

Does it make sense to block thread for 20mins to only wait on response?

In this case yes, clients require business logic that works that way, they write fully automated processes that runs that long tasks (and does not care about async tasks and signals), so we need that kind of thing

What is the cause of transaction rollback? (I would expect some kind of timeout -> increase timeout).

Transaction timeouts are typically set on the database level.
But keeping a transaction open for so long is not ideal for resources, isn’t there a way to solve this differently without keeping open a transaction (e.g. sending a message to a queue, handling it there such that it calls the slow task and then calls back to the process?)