dbus java DirectConnection FatalDBusException
Matthew Johnson
dbus at matthew.ath.cx
Thu Jan 12 03:42:52 PST 2012
On Thu Jan 12 10:27, Edgar Domingues wrote:
> Hi Matt,
>
> I only see the exceptions because I changed the catch blocks in
> AbstractConnection to log them.
> I ran the tests code (tests/test-p2p-client and server) and the
> results are the same (shown below).
> I don't mind that the client die after disconnecting. My problem is
> the server. I need the server to keep running after the client
> disconnects so it receives other clients. Looks like the server code
> blocks in "new DirectConnection" until a client connects and then dbus
> crashes after the client disconnects.
>
> There is some way of knowing if dbus is running or not, so the server
> can start listening again?
Well, it's kind of designed to be a single connection between two apps. If you
want a server which can accept multiple connections, first of all I'd suggest
using a bus, and secondly, I'd suggest looking at the implementation of the
DBusDaemon in the dbus-java source, which does a similar thing. You may have to
use some of the lower-level constructs.
Alternatively, I'm happy to accept patches if you find a more elegant solution
involving a change to dbus-java.
Matt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: Digital signature
URL: <http://lists.freedesktop.org/archives/dbus/attachments/20120112/2fde3446/attachment.pgp>
More information about the dbus
mailing list