[java] dbus disconnecting / threaded use of dbus
Matthew Johnson
dbus at matthew.ath.cx
Thu Sep 6 10:26:44 PDT 2012
On Thu Sep 06 11:54, Colby M White wrote:
> Thanks for the responses.
>
> Everything I can see indicates the messages are UTF-8 and thus the messages
> are legit. That wouldn't explain why sometimes it works and sometimes it
> fails though.
>
> I put the debug on all, but it's logging the bytes of the messages. Looking
> at that, I can't really tell if the messages are off.
No, but I was hoping I might (or someone else on this list), since there's
obviously _something_ wrong with them.
> One detail I left out is the Observable/Observer pattern I'm using. The
> Observer implements my DBusInterface and exports itself to the dbus. The
> Observable is a thread that runs and updates its state every so often. When
> the Observable updates, the DbusObserver gets the update and emits a signal
> to the dbus. Is this perhaps a bad design? Could having N Observers
> accessing the dbus be an issue? (I'm guessing no since the dbus library
> appears thread-safe. I'm somewhat grasping at straws now.)
Yeah, all that should be fine
> I went ahead and tried to create a small project to demonstrate the issue
> (mostly for myself). Again, sometimes it fails, sometimes it doesn't.
> Sometimes it takes a while to fail. If anyone somehow has the time/desire
> to dive into it, https://www.dropbox.com/s/ffbjp24h58s1yg3/dbus-test.tar.gz
I'll see if I have time to have a look
Matt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 835 bytes
Desc: Digital signature
URL: <http://lists.freedesktop.org/archives/dbus/attachments/20120906/f0080683/attachment.pgp>
More information about the dbus
mailing list