[EJB3] - Unsupported cache provider
by Somostetoi Kilato
Somostetoi Kilato [https://community.jboss.org/people/somostetoikilato] created the discussion
"Unsupported cache provider"
To view the discussion, visit: https://community.jboss.org/message/720557#720557
--------------------------------------------------------------
Hi,
I try to deploy a working (with JBoss 4.2.0) EJB3 application to JBoss 5.1.2 but I get these errors:
INFO [org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge] (HDScanner) Cache provider: org.jboss.ejb3.entity.TreeCacheProviderHook
ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] (HDScanner) Error installing to Start: name=persistence.unit:unitName=my.ear/ejb3-persistence.jar#myservices state=Create
javax.persistence.PersistenceException: [PersistenceUnit: myservices] Unable to build EntityManagerFactory
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:678)
at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:133)
at org.jboss.jpa.deployment.PersistenceUnitDeployment.start(PersistenceUnitDeployment.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.reflect.plugins.introspection.ReflectionUtils.invoke(ReflectionUtils.java:59)
at org.jboss.reflect.plugins.introspection.ReflectMethodInfoImpl.invoke(ReflectMethodInfoImpl.java:150)
at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(BasicMethodJoinPoint.java:66)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction$JoinpointDispatchWrapper.execute(KernelControllerContextAction.java:243)
at org.jboss.kernel.plugins.dependency.ExecutionWrapper.execute(ExecutionWrapper.java:47)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchExecutionWrapper(KernelControllerContextAction.java:111)
at org.jboss.kernel.plugins.dependency.KernelControllerContextAction.dispatchJoinPoint(KernelControllerContextAction.java:72)
at org.jboss.kernel.plugins.dependency.LifecycleAction.installActionInternal(LifecycleAction.java:221)
at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:54)
at org.jboss.kernel.plugins.dependency.InstallsAwareAction.installAction(InstallsAwareAction.java:42)
at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1652)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:938)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:988)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:778)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:543)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:125)
at org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer.deploy(BeanMetaDataDeployer.java:52)
at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1454)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1172)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1193)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1225)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1113)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1652)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:938)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:988)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:826)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:556)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:789)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:699)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.hibernate.HibernateException: could not instantiate RegionFactory [org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge]
at org.hibernate.cfg.SettingsFactory.createRegionFactory(SettingsFactory.java:394)
at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:266)
at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2118)
at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2114)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1338)
at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:867)
at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:670)
... 57 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.hibernate.cfg.SettingsFactory.createRegionFactory(SettingsFactory.java:389)
... 63 more
Caused by: org.hibernate.cache.CacheException: Could not instantiate cache provider: org.jboss.ejb3.entity.TreeCacheProviderHook
Unsupported cache provider implemention is not included our Product.
This error may be caused by the configured cache provider was not found in the classpath.
Please check the cache configuration and make sure the provider is in the classpath.
at org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge.<init>(RegionFactoryCacheProviderBridge.java:70)
... 68 more
Caused by: java.lang.ClassNotFoundException: org.jboss.ejb3.entity.TreeCacheProviderHook from mailto:BaseClassLoader@16bc6e5{vfsfile:/c:/jboss-eap-5.1.2/server/my/conf/jboss-service.xml BaseClassLoader@16bc6e5{vfsfile:/c:/jboss-eap-5.1.2/server/my/conf/jboss-service.xml}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:477)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:192)
at org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge.<init>(RegionFactoryCacheProviderBridge.java:62)
... 68 more
Please help me.
SK
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/720557#720557]
Start a new discussion in EJB3 at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
12 years, 10 months
[jBPM] - Resume a process after a crash
by liliana.iovanovici
liliana.iovanovici [https://community.jboss.org/people/liliana.iovanovici] created the discussion
"Resume a process after a crash"
To view the discussion, visit: https://community.jboss.org/message/720541#720541
--------------------------------------------------------------
I read the documentation about persistence and process recovery:
"If you configure the engine to use persistence, it will automatically store the runtime state into the database. You do not have to trigger persistence yourself, the engine will take care of this when persistence is enabled. Whenever you invoke the engine, it will make sure that any changes are stored at the end of that invocation, at so-called safe points. Whenever something goes wrong and you restore the engine from the database, you also should not reload the process instances and trigger them manually to resume execution, as process instances will automatically resume execution if they are triggered, like for example by a timer expiring, the completion of a task that was requested by that process instance, or a signal being sent to the process instance. The engine will automatically reload process instances on demand."
And I have some questions:
1. If I have a process: Start - Timer1- Script1- Timer2- Script2 -Stop and my process crash at Timer1 or Timer2, the jBPM engine will know to automatically to continue this process, and the tasks will be executed, without some thrird party mechanism (which look in databases and get session and process id and send some events) ?
2. The jBPM5 engine can be embeded or must be deployed standalone to do process recovery?
3. I dont't understand what means "The engine will automatically reload process instances on demand". If is "on demand" - is still "automatically" ?
Thanks,
Liliana
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/720541#720541]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
12 years, 10 months
[JNDI and Naming] - JNDI not resolving localhost to 127.0.0.1
by petal1
petal1 [https://community.jboss.org/people/petal1] created the discussion
"JNDI not resolving localhost to 127.0.0.1"
To view the discussion, visit: https://community.jboss.org/message/719937#719937
--------------------------------------------------------------
Hello,
I have an Amazon EC2 instance (could be any cloud server, or even any server I guess) running Open SuSE. I am running JBoss 4.0.4GA on there. When I do a JNDI lookup with a provider URL of "localhost:1099", I may get an error depending on what is in /etc/hosts.
What I don't understand is why JBoss is not resolving localhost to 127.0.0.1.
When /etc/hosts contains:
127.0.0.1 localhost
<external-ip-not-shown> MYHOSTNAME
then JBoss resolves localhost to the external IP. If the /etc/hosts file contains:
127.0.0.1 localhost
<internal-ip-not-shown> MYHOSTNAME
then JBoss resolves localhost to the internal IP.
So clearly /etc/hosts is involved in JBoss’s resolution of names. But when I do:
dig localhost +short +identify
It returns:
127.0.0.1 from server 172.16.0.23 in 80 ms.
Apparently Amazon EC2 instances don't have any awareness of their external IP, so the /etc/hosts should reference only the internal IP address. Indeed my application works fine when the /etc/hosts file contains only the internal IP but my issue is why JBoss does not resolve localhost to 127.0.0.1 ?
Just as a bit of extra info, I executed the code below:
InetAddress ina= InetAddress.getByName("localhost");
System.out.println("getCanonicalHostName()=" +ina.getCanonicalHostName());
System.out.println("getHostAddress()=" +ina.getHostAddress());
System.out.println("getHostName()=" +ina.getHostName());
System.out.println("toString()=" +ina.toString());
and it returned:
getCanonicalHostName()=localhost
getHostAddress()=127.0.0.1
getHostName()=localhost
toString()=localhost/127.0.0.1
Thank you for any help.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/719937#719937]
Start a new discussion in JNDI and Naming at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
12 years, 10 months