I have a database running in server mode on port 6136 on server1 and server2. Each server has a replicated copy of the other servers database.
I try to open the replicated on one database for a query (just read, no update) but it fails with the error below. The code I'm using is (user & password has been deliberately removed):
EntityManagerFactory emf = Persistence.createEntityManagerFactory( "objectdb://SE101388:6136//SE101352:6136/WorkflowHistory.odb;user=...;password=..."); EntityManager em = emf.createEntityManager();
The exception is thrown by the createEntityManager call.
The exception is:
[ObjectDB 2.2.8] javax.persistence.PersistenceException Attempt to update types in read only mode (error 614) at com.objectdb.jpa.EMF.createEntityManager(EMF.java:163) at rbccm.felix.gridservice.admin.dao.ConnectionManagerFactory.createEntityManager(Unknown Source) at rbccm.felix.gridservice.admin.dao.SimpleWorkflowInstanceQueryDao.queryInstance(Unknown Source) at rbccm.felix.gridservice.admin.dao.SimpleWorkflowInstanceQueryDao.queryComplete(Unknown Source) at rbccm.felix.gridservice.admin.AdminQueryService.process(Unknown Source) at rbccm.felix.framework.service.ServiceRunner.run(Unknown Source) at java.lang.Thread.run(Thread.java:595) Caused by: com.objectdb.o.UserException: Attempt to update types in read only mode at com.objectdb.o.MSG.d(MSG.java:61) at com.objectdb.o.SHN.ab(SHN.java:364) at com.objectdb.o.SHN.J(SHN.java:124) at com.objectdb.o.HND.run(HND.java:133) ... 1 more