Infinispan seems not the correc forum, move to WildFly
I'm not sure about your use-case.
Did you start a transactional EJB and have it running for 2 hours?
Could you elaborate on this?
Yes, you are correct. Starting the EJB transaction, which takes around 2 hours to complete its conversion. Once converted then on words need to have data base operations to store the converted records.
You need to set the transaction timeout like this
@TransactionTimeout(value = 10, unit = TimeUnit.SECONDS)
But a better solution is to use a method without Tx to collect the results and invoke another method annotated with Tx.REQUIRED to store it.
Note, you need to invoke the method with a proxy (like a different EJB) as with a direct Java method invocation the container is not involved and there is no transaction started.