Probably it is a basic question, but could not found the answer anywhere in the web.
I am trying to use a second level cache (using ehcache) and just checked that some objects were being retrieved from database every time I tried to load them, the only difference was that I was not getting them by id but by a property that carries a SEO friendly name that are used to create urls on the system I am working. Is jpa/hibernate able to retrieve objects from cache just by with the id of the obj? Is there any way to get it working without need to activate the query cache?