public class NuxeoContainer extends Object
This code is called by the factories registered through JNDI, or by unit tests mimicking JNDI bindings.
Modifier and Type | Class and Description |
---|---|
static class |
NuxeoContainer.ConnectionManagerWrapper
Wraps a Geronimo ConnectionManager and adds a
NuxeoContainer.ConnectionManagerWrapper.reset() method to flush the pool. |
static class |
NuxeoContainer.InstallContext |
static class |
NuxeoContainer.TransactionManagerConfiguration |
static class |
NuxeoContainer.TransactionManagerWrapper
Wraps a transaction manager for providing a dummy recoverable interface.
|
static class |
NuxeoContainer.UserTransactionImpl
User transaction that uses this container's transaction manager.
|
Modifier and Type | Field and Description |
---|---|
protected static com.codahale.metrics.Counter |
concurrentCount |
protected static com.codahale.metrics.Counter |
concurrentMaxCount |
protected static Map<String,NuxeoContainer.ConnectionManagerWrapper> |
connectionManagers |
protected static String |
jndiPrefix |
protected static org.apache.commons.logging.Log |
log |
protected static Context |
parentContext |
protected static com.codahale.metrics.MetricRegistry |
registry |
protected static com.codahale.metrics.Counter |
rollbackCount |
protected static Context |
rootContext |
protected static ConcurrentHashMap<Transaction,com.codahale.metrics.Timer.Context> |
timers |
protected static TransactionManager |
tm |
protected static org.apache.geronimo.transaction.manager.RecoverableTransactionManager |
tmRecoverable |
protected static TransactionSynchronizationRegistry |
tmSynchRegistry |
protected static com.codahale.metrics.Timer |
transactionTimer |
protected static UserTransaction |
ut |
protected static final org.apache.commons.logging.Log log
protected static org.apache.geronimo.transaction.manager.RecoverableTransactionManager tmRecoverable
protected static TransactionManager tm
protected static TransactionSynchronizationRegistry tmSynchRegistry
protected static UserTransaction ut
protected static Map<String,NuxeoContainer.ConnectionManagerWrapper> connectionManagers
protected static Context rootContext
protected static Context parentContext
protected static String jndiPrefix
protected static final com.codahale.metrics.MetricRegistry registry
protected static final com.codahale.metrics.Counter rollbackCount
protected static final com.codahale.metrics.Counter concurrentCount
protected static final com.codahale.metrics.Counter concurrentMaxCount
protected static final com.codahale.metrics.Timer transactionTimer
protected static final ConcurrentHashMap<Transaction,com.codahale.metrics.Timer.Context> timers
protected static void install() throws NamingException
NamingException
protected static void installTransactionManager(NuxeoContainer.TransactionManagerConfiguration config) throws NamingException
NamingException
public static NuxeoContainer.ConnectionManagerWrapper installConnectionManager(NuxeoConnectionManagerConfiguration config)
name
- the repository nameconfig
- the pool configurationpublic static boolean isInstalled()
protected static void uninstall() throws NamingException
NamingException
public static void addListener(NuxeoContainerListener listener)
public static void removeListener(NuxeoContainerListener listener)
protected static String detectJNDIPrefix(Context context)
public static Context getRootContext()
rootContext
.https://jira.nuxeo.com/browse/NXP-10331
public static void addDeepBinding(String name, Object obj) throws NamingException
NamingException
protected static void addDeepBinding(Context dir, CompositeName comp, Object obj) throws NamingException
NamingException
protected static void addBinding(Context dir, Name name, Object obj) throws NamingException
NamingException
protected static void removeBinding(String name) throws NamingException
NamingException
public static TransactionManager getTransactionManager()
protected static Reference getTransactionManagerReference()
public static UserTransaction getUserTransaction()
protected static Reference getUserTransactionReference()
public static NuxeoConnectionManager getConnectionManager(String repositoryName)
public static void installConnectionManager(NuxeoContainer.ConnectionManagerWrapper wrapper)
protected static Reference getConnectionManagerReference(String name)
protected static TransactionManager initTransactionManager(NuxeoContainer.TransactionManagerConfiguration config)
protected static NuxeoContainer.TransactionManagerWrapper wrapTransactionManager(TransactionManager tm)
public static NuxeoContainer.ConnectionManagerWrapper initConnectionManager(NuxeoConnectionManagerConfiguration config)
public static void disposeConnectionManager(javax.resource.spi.ConnectionManager mgr)
public static void resetConnectionManager()
public static void resetConnectionManager(String name)
public static <T> T lookup(String name, Class<T> type) throws NamingException
NamingException
public static <T> T lookup(Context context, String name, Class<T> type) throws NamingException
NamingException
protected static void installTransactionManager(Context context) throws NamingException
NamingException
protected static NuxeoContainer.ConnectionManagerWrapper lookupConnectionManager(String repositoryName) throws NamingException
NamingException
protected static org.apache.geronimo.transaction.manager.TransactionManagerImpl createTransactionManager(NuxeoContainer.TransactionManagerConfiguration config)
public static NuxeoConnectionManager createConnectionManager(NuxeoConnectionTrackingCoordinator coordinator, NuxeoConnectionManagerConfiguration config)
The pool uses the transaction manager for recovery, and when using XATransactions for cache + enlist/delist.
NamingException
protected static org.apache.geronimo.connector.outbound.connectionmanagerconfig.PoolingSupport createPoolingSupport(NuxeoConnectionManagerConfiguration config)
protected static org.apache.geronimo.connector.outbound.connectionmanagerconfig.TransactionSupport createTransactionSupport(NuxeoConnectionManagerConfiguration config)
protected static NuxeoValidationSupport createValidationSupport(NuxeoConnectionManagerConfiguration config)
public static TransactionSynchronizationRegistry getTransactionSynchronizationRegistry()
Copyright © 2018 Nuxeo. All rights reserved.