I agree that more docs would be helpful for this. I think removing the
default cache is fine, but it should probably log a WARN message if used
without a real cache then.

On Tue, Sep 11, 2018 at 6:37 AM Andrus Adamchik <[email protected]>
wrote:

> I've been working on Cayenne training class material lately. This was the
> first opportunity I had in a long time to look at the big picture as far
> the the current query caching is concerned. A few random comments...
>
> Currently there are three main pieces to a caching solution:
>
> 1. QueryCache service in "cayenne-server"
> 2. "cayenne-jcache" module with extra libs like "ehcache", and custom
> config files
> 3. "cayenne-cache-invalidation" - allows to flush caches on commit.
>
> With module auto-loading, and "contribute" API, all this is *very* easy to
> use ... if you already know what to do. If you don't, you'll bang your head
> against the wall trying to figure out a proper way to add cache. In other
> words we need to document the main recipe - which modules to include and
> how to pass a config file.
>
> Also it is probably more logical to turn off query caching completely in a
> default setting. Currently we use MapQueryCache that is an unmanaged LRU
> map. I think the default should be a dummy no-cache strategy. This will
> emphasize the fact that any real cache management happens outside Cayenne
> core.
>
> Andrus
>
>
>
>
>
>
>

Reply via email to