ClassNotFoundException: org.jgroups.ChannelFactory in EAP 6

Solution Verified - Updated -

Issue

  • While migrating the application from eap 5.1 to 6.1.0, getting the following below exceptions,
Caused by: org.hibernate.HibernateException: could not instantiate RegionFactory [org.hibernate.cache.jbc2.JndiMultiplexedJBossCacheRegionFactory]
        at org.hibernate.cfg.SettingsFactory.createRegionFactory(SettingsFactory.java:501)
        at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:289)
        at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2283)
        at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2279)
        at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1748)
        at org.hibernate.ejb.EntityManagerFactoryImpl.<init>(EntityManagerFactoryImpl.java:94)
        at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:920)
        ... 9 more
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.6.0_45]
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) [rt.jar:1.6.0_45]
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) [rt.jar:1.6.0_45]
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513) [rt.jar:1.6.0_45]
        at org.hibernate.cfg.SettingsFactory.createRegionFactory(SettingsFactory.java:484)
        ... 15 more
Caused by: java.lang.NoClassDefFoundError: org/jgroups/ChannelFactory
        at org.hibernate.cache.jbc2.JndiMultiplexedJBossCacheRegionFactory.<init>(JndiMultiplexedJBossCacheRegionFactory.java:65)
        at org.hibernate.cache.jbc2.JndiMultiplexedJBossCacheRegionFactory.<init>(JndiMultiplexedJBossCacheRegionFactory.java:57)
        ... 20 more
Caused by: java.lang.ClassNotFoundException: org.jgroups.ChannelFactory from [Module "deployment.XXXX.ear:main" from Service Module Loader]
        at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:196) [jboss-modules.jar:1.2.0.Final-redhat-1]
        at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:444) [jboss-modules.jar:1.2.0.Final-redhat-1]
  • The org.jgroups.ChannelFactory is used for clustering, however, there are no intensions of enabling Clustering here when the above exception(s) is popped up.

  • The Hibernate version that's used here is Hibernate 4.x.

Environment

  • Redhat JBoss Enterprise Application Platform (EAP)
    • 6.1.0

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.