Chytry
Chytry

Reputation: 367

Grails - Where it is stored cache

I'm using cache in Grails in this way:

class Book {
…
static mapping = {
    cache true
}

}

I have many instances of application. I want write REST API for cache, but I don't know where can I find it. All instances are using one database. Is the cache is stored in a database or on the machine where the application stands . If so, where ?

UPDATE. It's my hibernate config for cache

hibernate {
cache.use_second_level_cache = true
cache.use_query_cache = true
cache.provider_class = 'net.sf.ehcache.hibernate.EhCacheProvider'
}

Upvotes: 1

Views: 189

Answers (1)

Jeff Scott Brown
Jeff Scott Brown

Reputation: 27255

Is the cache is stored in a database or on the machine where the application stands . If so, where ?

I can't be sure but will assume that you are using Hibernate. If that is the case, the best answer that I could offer is that it depends on how you have configured your Hibernate 2nd level cache. There is no way to know that from just looking at the question.

Upvotes: 1

Related Questions