Package org.infinispan.commons.tx.lookup
Class LookupNames
java.lang.Object
org.infinispan.commons.tx.lookup.LookupNames
The JDNI and
TransactionManager
factories we know of.- Since:
- 9.3
- Author:
- Pedro Ruivo
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
JNDI locations for TransactionManagers we know of.static enum
TransactionManager factories we know of. -
Method Summary
Modifier and TypeMethodDescriptionstatic Optional<javax.transaction.TransactionManager>
Lookup for aTransactionManager
by known JNDI names.static Optional<javax.transaction.TransactionManager>
lookupByTransactionManagerFactory
(ClassLoader classLoader) Lookup aTransactionManager
by factory.static Optional<javax.transaction.TransactionManager>
lookupKnownTransactionManagers
(ClassLoader classLoader) Lookup forTransactionManager
.
-
Method Details
-
lookupKnownTransactionManagers
public static Optional<javax.transaction.TransactionManager> lookupKnownTransactionManagers(ClassLoader classLoader) Lookup forTransactionManager
.It looks up by JNDI first using
lookupByJNDI()
and then byTransactionManager
factories, usinglookupByTransactionManagerFactory(ClassLoader)
.- Parameters:
classLoader
- TheClassLoader
to be used bylookupByTransactionManagerFactory(ClassLoader)
- Returns:
- An
Optional
with theTransactionManager
if found.
-
lookupByJNDI
Lookup for aTransactionManager
by known JNDI names.- Returns:
- An
Optional
with theTransactionManager
if found.
-
lookupByTransactionManagerFactory
public static Optional<javax.transaction.TransactionManager> lookupByTransactionManagerFactory(ClassLoader classLoader) Lookup aTransactionManager
by factory.- Parameters:
classLoader
- TheClassLoader
to use to instantiate the factory.- Returns:
- An
Optional
with theTransactionManager
if found.
-