Hello. I have a standalone JAVA project using Hibernate (works perfectly fine).
I copied the same project on another computer but I encounter this problem: 1. Updates done on Project A is not reflected on Project B, and vice versa. But, the database is updated - both from these two projects.
To check further, I tried making an update directly from the database when Project A or B is already running. However, it appears that it doesn't get any updates unless it is from itself. I put a button in the Project to re-query: Session session= HibernateUtil.getSessionFactory().openSession(); Query..... session.flush(); session.close();
But, after restarting the project - the updates can already be found.
I believe it is associated with caching. what should be my configurations in hibernate.cfg?
Thanks a lot
|