Does anyone have any experience enabling Hibernate second-level caching with jBPM? Things like User, Deployment and more are practically never changed in our application, and could easily be cached to reduce the amount of database queries.
I can get it to work by writing my own custom criteria searches, adding setCacheable(true), but nothing else seems to have any effect. Re-implementing the whole API just to add that one line to all criterias does not seem like a good idea.
Does anyone have any hints or tips regarding this? Right now our application drowns in database requests with a few hundred active process-instances, and we need it to scale up to at least 10 000.
Documentation suggests that the Deployment objects are cached, but as far as I can tell that is not happening in our application.
We are using Spring to set up the SessionFactory. Could this be the problem?