Class ThreadTxn

java.lang.Object
org.apache.jena.system.ThreadTxn

public class ThreadTxn extends Object
An action that will happen on a different thread later when ThreadAction.run() is called. A thread is created and the transaction started during a call to the creation operations threadTxnRead(org.apache.jena.sparql.core.Transactional, java.lang.Runnable) or threadTxnWrite(org.apache.jena.sparql.core.Transactional, java.lang.Runnable). The associated Runnable is called and the transaction completed when ThreadAction.run() is called. Being on a thread, the state of the world the forked transaction sees is outside the creating thread which may itself be in a transaction. Warning: creating a write transaction inside a write transaction will cause deadlock.