Hi Roland,
As you suspected, calling ice_getConnection behaves similarly to making a synchronous proxy invocation, in that calling it from the Qt dispatch thread will cause the program to hang.
The proxy also provides the method ice_getCachedConnection, but this method returns null if no connection has been established yet.
To avoid blocking, I recommend calling begin_ice_ping. Upon successful completion, the connection will be established and you can do something like this in the completion callback:
Code:
Ice::ConnectionPtr conn = proxy->ice_getCachedConnection();
assert(conn);
conn->setAdapter(...);
We'll consider adding a better solution to a future Ice release.
Regards,
Mark