I am wondering how I disable cache on a per Query basis to ensure the latest
data?
In my code I am select a list of jobs to be displayed in the view. The status
of the jobs gets updated frequently, however the changes are not being shown in
the view. In the output of jboss, I do get the sql being generated, so I know
a database call is happening, I am assuming the data being returned is cached
data.
How Do I indicate to the entity manager NOT to cache this data, or to force a
fresh retrieval?
| ...
|
| Map parameters = new HashMap();
| StringBuffer queryString = new StringBuffer();
| queryString.append("from Job");
| Query query = em.createQuery(queryString.toString());
| jobs = (List<Job>) query.getResultList();
|
| ...
|
Thanks.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3975505#3975505
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3975505
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user