Re: [Beankeeper-discussion] error when adding object to list
Brought to you by:
demonsystem
From: Shay M. <mat...@gm...> - 2009-03-03 00:18:57
|
Hi, Is there a way to identify the transition stage in which a server node has gone down, and the clients are busy choosing a new server node, in order to retry the query? Actually, it would be even better if the store itself would wait and retry the query instead of throwing an exception. Thanks, Shay Brautigam Róbert wrote: > Shay Matasaro írta: > >> Hi Róbert, >> >> firstly , I'd like to thank you for your help . >> > > No problem, I learn as much as you do. > > ... > >> i have setup the store as a singleton. >> >> but I am running 2 application at any given moment , one is a web app >> under glassfish , and the other is a standalone console app that i use >> for testing, debugging , etc... >> >> are they interfering with each other? >> >> although i am running both from within Nebeans , i assumed they were >> using different JVMs >> > > Even if they are in different JVMs, two BeanKeeper nodes accessing the > same database will connect to eachother and exchange synchronization and > other data that is necessary to ensure atomicity, etc of operations. So > yes, they are interfering. > This is not a problem though, it should work unless the appointed server > node (which is usually what started first) is stopped, in which case the > client nodes have no other option than to indicate the error and > reorganize around a new server node. > > >> the console app completes its tasks and the shuts down , while the web >> app is stopped when i deploy a new version , i also often breakpoint >> both apps in debugging mode. >> >> is this the wrong way to do things? >> >> which approach do you recommend? >> > > It should be ok, as long as both are running. If one is shut down, the > other might throw a few errors indicating that the server node just went > down. After that is should come back as a server. > > >> Thanks, >> Shay >> >> >> Brautigam Róbert wrote: >> >>> Shay Matasaro írta: >>> >>> >>>> Hi, >>>> >>>> i am getting the following exception when attempting to add an object >>>> to a List. >>>> >>>> hu.netmind.persistence.DatabaseFactory - got data source to: >>>> PostgreSQL (8.3.6) through driver: PostgreSQL Native Driver >>>> (PostgreSQL 8.3 JDBC3 with SSL (build 603)) >>>> Exception in thread "main" hu.netmind.persistence.StoreException: >>>> client thread is shutting down, so no response will be available. >>>> 2009-03-02 02:50:18,177 [Persistence-client] ERROR >>>> hu.netmind.persistence.node.NodeClient - error while listening for >>>> server events. >>>> >>>> >>> Hello, >>> >>> This is only possible, if you had multiple BeanKeeper Stores running at >>> the same time. This happens when the server node shuts down, in which >>> case the clients will abort all running transactions. >>> Be sure you have only one node running, or don't close the other nodes >>> during the operation. >>> >>> Robert. >>> >>> >>> >> > > > |