It's a timer that eventually times out the transaction (with default settings after 300 seconds), activity of the thread is not measured (how would you do that in Java?)
That was what I thought!
My hope was that Jboss would at least reset the timer if it found the thread still active!
I know that it is properly impossible to monitor thread activity in Java but a simple solution would have been each time the thread make a successful call to a EJB (or any application server controlled resource) the timer could be reset, this wont happen if the call causes deadlock between two transactions.
I think this would have worked because the call is intercepted by Jboss