Hi,

On Fri, 2012-11-23 at 21:48 +0100, Alexander Lang wrote:
> Hello,
> i would like the client application to remain responsive after the
> connection to the render servers has been initialized. The
> MultiDisplayWindow::init() function blocks until all render servers have
> connected, therefore i would like to call init or initAsync on the
> MultiDisplayWindow instance in another thread.
> 
> I changed the code of the testDynamicClusterClient.cpp file (attached)
> such that on connection request a thread is created that operates on
> aspect 1. After that, the function in the main thread returns.
> 
> The MultiDisplayWindow pointer is changed to a MTRecPtr such that it will
> be available in the connection thread. After the thread is synced to the
> main thread, initAsync is called. Once a server connected, the thread
> waits on a barrier.
> 
> The main thread continuously polls if the thread is waiting on the barrier
> and if so, pulls the changes from the connection thread to the main
> thread.
> The connection thread then finishes.
> 
> This works until i want to disconnect. Setting the
> MultiDisplayWindowMTRecPtr to NULL does not free the object, the
> connection is lost but the server window is not closed. At this point only
> the main thread exists, therefore i am puzzled what could keep the window
> from being destroyed. Any ideas?
> 
> P.S. How about an explicit ClusterWindow::disconnect() that would set any
> pointers that refer to the window instance to NULL, like the WeakPtr?

hmm, this has nothing directly to do with the clustering. It is more
related to the multi-threading in general. I'll have a look.

kind regards
  gerrit



------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Opensg-users mailing list
Opensg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to