Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9157855
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T13:07:09+00:00 2026-06-17T13:07:09+00:00

Have such ehcache configuration: <ehcache> <terracottaConfig url=192.168.1.4:9510/> <defaultCache maxElementsInMemory=50 eternal=false timeToIdleSeconds=20 timeToLiveSeconds=20 overflowToDisk=false diskPersistent=false

  • 0

Have such ehcache configuration:

<ehcache>                                                                                                                                                                                                                                      

  <terracottaConfig url="192.168.1.4:9510"/>                                                                                                                                                                                                           

  <defaultCache                                                                                                                                                                                                                                
      maxElementsInMemory="50"                                                                                                                                                                                                                 
      eternal="false"                                                                                                                                                                                                                          
      timeToIdleSeconds="20"                                                                                                                                                                                                                   
      timeToLiveSeconds="20"                                                                                                                                                                                                                   
      overflowToDisk="false"                                                                                                                                                                                                                   
      diskPersistent="false"                                                                                                                                                                                                                   
      memoryStoreEvictionPolicy="LRU"                                                                                                                                                                                                          
      />                                                                                                                                                                                                                                       

  <cache name="foo"                                                                                                                                                                                                              
         maxElementsInMemory="50000"                                                                                                                                                                                                           
         eternal="true">                                                                                                                                                                                                                       
    <terracotta />                                                                                                                                                                                                                             
  </cache>                                                                                                                                                                                                                                     

</ehcache> 

It does not work, application just does not conntects to terracotta server, however during startup it throws such Exception:

 net.sf.ehcache.ObjectExistsException: Cache foo already exists. 

When I enabled ehcache debug logs, I don’t see that my ehcache.xml is loaded somewhere (althrough another ehcache.xml which sits on the classpath inside some jar file is loaded). What could be a problem?

My grails version is 2.1.1, ehcache.xml sits on grails-app/conf directory.

UPDATE 1
One more explanation. cache named foo is used in ehcache.xml and in the code as referece (actually in Apache Camel route as to(‘cache://foo’). When I rename foo in code to bar (e.g. route now looks like to(‘cache://bar’) it throws the exception that Cache bar already exists. So, exception comes not from ehcache.xml configuration file, but from code referencing that cache by name. Any suggestions would be highly appreciated.

UPDATE 2
Seems the exception is thrown because there are 2 places inside camel routes where cache://foo is referenced. When 2nd reference is reached it throws that exception. So the main question is, why ehcache.xml is not seen by the application on startup? It should warm up and prepare cache://foo for future use.

UPDATE 3
It apparently worked before on grails 1.3.7. And now it does not work on grails 2.1.1

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T13:07:10+00:00Added an answer on June 17, 2026 at 1:07 pm

    When I run grails with -noreloading option it works well. Must be some classpath issue.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Have such user_session model: class UserSession < Authlogic::Session::Base logout_on_timeout true # default if false
I have such jquery code: $(.quantity).blur(function() { console.log(upd); $.ajax({ url: /line_items/update_quantity/, type: GET, data:
have such zend query: $select = $this->_table ->select() ->where('title LIKE ?', '%'.$searchWord.'%') ->where('description LIKE
i have such code (copy paste from wiki). Its multiplication of those big numbers
I have such XML structure which was returned by SharePoint web services. <rs:data ItemCount=4
i have such function to solve some logic riddle iloczyny is list with such
I have such a grid square disk. Every grid represents a pixel. My aim
I have such tables in my database like Customer , Member , Instructor ,
I have such problem: I'm using rails, devise gem and jQuery validation plugin. I
I have such a for loop: for (var i = 0; i < documentsCount;

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.