-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: EhCache Initialization Exception
PostPosted: Mon Jul 03, 2006 7:30 am 
Newbie

Joined: Mon Jul 03, 2006 7:11 am
Posts: 1
Hello,
We used ehCache in our project, initializing it like this:

Code:
net.sf.ehcache.CacheManager.create()


Now we involved Hibernate and as it also initializes the CacheManager and does it first, the second initialization does not work anymore throwing:

Code:
net.sf.ehcache.CacheException: Cannot parseConfiguration CacheManager. Attempt to create a new instance of CacheManager using the diskStorePath "C:\DOCUME~1\detelin\LOCALS~1\Temp\" which is already used by an existing CacheManager.


The ehCache documentation states the the CacheManager's create() method should return the existing singleton instance if one is present, but it does throw an exception instead.

Does anybody know how we can solve this?
We use hibernate 3.2.0 and the ehcache-1.2.jar that comes with it.

Thanks in advance,
Detelin


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 04, 2006 7:02 am 
Newbie

Joined: Thu Nov 30, 2006 12:21 pm
Posts: 14
did you find I solution of your problem ? I got the same things with hibernate 3.2 and ehcache1.2


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 11, 2006 1:24 pm 
Newbie

Joined: Wed Mar 15, 2006 10:56 am
Posts: 8
Location: Ohio USA
This is because of the file
ehcache-failsafe.xml which ahs the following entry

<diskStore path="can be one of the following"/>
user.home - User's home directory
user.dir - User's current working directory
java.io.tmpdir - Default temp file path

and usually this error happens if your application server has not released the lock on this folder for creating the ehCahe

make this to user.home and ensure that
eternal="false"
with
diskPersistent="true"

this will make sure that the objects are wriiten once between your re-start your application server.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.