You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Ravi Puri <ra...@gmail.com> on 2016/04/11 09:45:23 UTC

hibernate open session error while running with tomcat server

this is the error throws while executing with 

 long start = System.currentTimeMillis();
        System.out.println("Entering into loadCache
ApacheIgniteCacheConfiguration");
        // Start loading cache from persistent store on all caching nodes.
      cache.loadCache(null,100_000);// here throws the error
    
      System.out.println("after cache loadcache");
        long end = System.currentTimeMillis();

        System.out.println(">>> Loaded " + cache.size() + " keys with
backups in " + (end - start) + "ms.");
        System.out.println("Exiting from loadCache
ApacheIgniteCacheConfiguration");



error:


java.lang.NoSuchMethodError:
org.hibernate.SessionFactory.openSession()Lorg/hibernate/Session;

org.apache.ignite.cache.store.hibernate.CacheHibernateStoreSessionListener.onSessionStart(CacheHibernateStoreSessionListener.java:178)

org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.sessionInit0(GridCacheStoreManagerAdapter.java:818)

org.apache.ignite.internal.processors.cache.store.GridCacheStoreManagerAdapter.loadCache(GridCacheStoreManagerAdapter.java:479)

org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter.localLoadCache(GridDhtCacheAdapter.java:515)

org.apache.ignite.internal.processors.cache.IgniteCacheProxy.localLoadCache(IgniteCacheProxy.java:387)

org.apache.ignite.internal.processors.cache.GridCacheAdapter$LoadCacheClosure.call(GridCacheAdapter.java:5716)

org.apache.ignite.internal.processors.cache.GridCacheAdapter$LoadCacheClosure.call(GridCacheAdapter.java:5663)

org.apache.ignite.internal.processors.closure.GridClosureProcessor$C2.execute(GridClosureProcessor.java:1789)

org.apache.ignite.internal.processors.job.GridJobWorker$2.call(GridJobWorker.java:509)

org.apache.ignite.internal.util.IgniteUtils.wrapThreadLoader(IgniteUtils.java:6397)

org.apache.ignite.internal.processors.job.GridJobWorker.execute0(GridJobWorker.java:503)

org.apache.ignite.internal.processors.job.GridJobWorker.body(GridJobWorker.java:456)
	org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:110)
	java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	java.lang.Thread.run(Unknown Source)



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/hibernate-open-session-error-while-running-with-tomcat-server-tp4050.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: hibernate open session error while running with tomcat server

Posted by Kamal C <ka...@gmail.com>.
Ravi,

Check whether you have multiple versions of hibernate in your class path.

--Kamal
On 13-Apr-2016 4:42 AM, "vkulichenko" <va...@gmail.com> wrote:

> Ravi,
>
> You should double-check your classpath. This is the same or very similar
> issue, which is not about Ignite, but about your project structure.
>
> -Val
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/hibernate-open-session-error-while-running-with-tomcat-server-tp4050p4102.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>

Re: hibernate open session error while running with tomcat server

Posted by vkulichenko <va...@gmail.com>.
Ravi,

You should double-check your classpath. This is the same or very similar
issue, which is not about Ignite, but about your project structure.

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/hibernate-open-session-error-while-running-with-tomcat-server-tp4050p4102.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: hibernate open session error while running with tomcat server

Posted by Ravi Puri <ra...@gmail.com>.
yea it was fixed when i used to run the project as an individual but when i
try to integrate with other project it throws an error . as i use all the
jars to refr the othr project but stil it throws an error.



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/hibernate-open-session-error-while-running-with-tomcat-server-tp4050p4093.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.

Re: hibernate open session error while running with tomcat server

Posted by vkulichenko <va...@gmail.com>.
Hi Ravi,

This looks like exactly the same issue you were reporting earlier. You were
able to fix the classpath, right? Is it possible that the fix was not
applied somewhere?

-Val



--
View this message in context: http://apache-ignite-users.70518.x6.nabble.com/hibernate-open-session-error-while-running-with-tomcat-server-tp4050p4073.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.