public GeronimoFactory() {
}
public TransactionManager getTransactionManager() {
Kernel kernel = KernelRegistry.getSingleKernel();
TransactionContextManager ctxManager = null;
try {
ctxManager = (TransactionContextManager) kernel.getGBean(TransactionContextManager.class);
} catch (GBeanNotFoundException except) {
throw new RuntimeException( "Can't lookup GBean: " + TransactionContextManager.class, except);
}
MultiParentClassLoader loader = (MultiParentClassLoader) ctxManager.getClass().getClassLoader();
// Add Jencks to Geronimo's root classloader to avoid InvalidAccessError
AbstractNameQuery abstractNameQuery = new AbstractNameQuery(null, Collections.EMPTY_MAP, Repository.class.getName());
Set set = kernel.listGBeans(abstractNameQuery);
for (Iterator iterator = set.iterator(); iterator.hasNext();) {