PDA

View Full Version : DBUS Confusion


spycedtx
02-28-2007, 08:06 PM
I'm attempting to access EDS services, and running into an obstacle.

When attempting to access, a supposedly synchronous call, to EDS, I'm receiving an error message of:

Message did not receive a reply (timeout by message bus)

Here is the offending code, within a static void section linked to a menu action:

EBook *mybook = e_book_new_from_uri("/home/adam/books/adambook", &err);
if (mybook == NULL)
{
hildon_banner_show_information(GTK_WIDGET(app->window), NULL, err->message);
}


I've gone through numerous iterations of changing the service name registered in the code, the .service file, the .desktop file, all to the same result. I've tried "my.own.domain.myservice", as well as the prior required "com.nokia.myservice". I'm afraid I might have missed a particular combination of where to (not) include the domain between the code and descriptors.

I'm hoping some guru can lend a hand or direction. I'm running this under 2.2, scratchbox 1, with a PC target. I've tried running dbus-monitor (i swear i used to be able to use the keyboard from within the xterm app under scratchbox), but I really don't know what I'm looking for. I do see calls to the addressbook and said factories.

I hope I've provided enough information to go on.... Thanks for any help!

For the sake of brevity, all tests to make sure things are initialized aren't pasted in here.. but, they're in the code, and they come back a success.

Initialization code, tried with and without "TRUE":

appData.context = osso_initialize("myapplication", "1.0", TRUE, NULL);


osso abook init code (tried with and without)

if (!osso_abook_init (&argc, &argv, appData.context))



myapplication.desktop:

Encoding=UTF-8
Version=1.0
Name=AddressApp
Comment=Address Book stuff
Exec=/home/adam/hello-world-gtk/hildpc/src/ihello
Icon=terminal
Terminal=false
Type=Application
Categories=User;Contact
X-HildonDesk-ShowInToolbar=true
X-Osso-Service=com.nokia.myapplication
X-Osso-Type=application/x-executable


myapplication.service

[D-BUS Service]
Name=com.nokia.myapplication
Exec=/home/adam/hello-world-gtk/hildpc/src/ihello

spycedtx
03-01-2007, 04:57 AM
Here's the output from dbus-monitor, if it helps, when running the e_book_new_from_uri().

with the null destination lines, I can't help but wonder if there's something broken in my dbus registrations.


method call sender=:1.6 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=StartServiceByName
string "org.gnome.evolution.dataserver.AddressBook"
uint32 0
signal sender=org.freedesktop.DBus -> dest=(null destination) interface=org.freedesktop.DBus; member=NameOwnerChanged
string ":1.7"
string ""
string ":1.7"
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=Hello
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=AddMatch
string "type='signal',sender='org.freedesktop.DBus',path='/org/freedesktop/DBus',interface='org.freedesktop.DBus',member='Nam eOwnerChanged'"
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=AddMatch
string "type='signal',sender='org.freedesktop.DBus',path='/org/freedesktop/DBus',interface='org.freedesktop.DBus'"
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=GetNameOwner
string "org.freedesktop.DBus"
signal sender=org.freedesktop.DBus -> dest=(null destination) interface=org.freedesktop.DBus; member=NameOwnerChanged
string "org.gnome.evolution.dataserver.AddressBook"
string ""
string ":1.7"
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=RequestName
string "org.gnome.evolution.dataserver.AddressBook"
uint32 0
method call sender=:1.6 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=GetNameOwner
string "org.gnome.evolution.dataserver.AddressBook"
method call sender=:1.6 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=AddMatch
string "type='signal',sender='org.freedesktop.DBus',path='/org/freedesktop/DBus',interface='org.freedesktop.DBus',member='Nam eOwnerChanged'"
method call sender=:1.6 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=AddMatch
string "type='signal',sender=':1.7',path='/org/gnome/evolution/dataserver/addressbook/BookFactory',interface='org.gnome.evolution.datase rver.addressbook.BookFactory'"
method call sender=:1.7 -> dest=org.freedesktop.DBus interface=org.freedesktop.DBus; member=AddMatch
string "type='signal',sender='com.nokia.backup',path='/com/nokia/backup',interface='com.nokia.backup'"
signal sender=org.freedesktop.DBus -> dest=(null destination) interface=org.freedesktop.DBus; member=NameOwnerChanged
string "org.gnome.evolution.dataserver.AddressBook"
string ":1.7"
string ""
signal sender=org.freedesktop.DBus -> dest=(null destination) interface=org.freedesktop.DBus; member=NameOwnerChanged
string ":1.7"
string ":1.7"
string ""

aflegg
03-01-2007, 05:05 AM
You'd probably be better off on the maemo-developers mailing list.

HTH,

Andrew

spycedtx
03-01-2007, 05:22 AM
Thanks for the heads up. I'm scouring the list archives now. I'll refrain from the grumbling on the lack of a search feature. :)

henry
03-01-2007, 07:26 AM
Thanks for the heads up. I'm scouring the list archives now. I'll refrain from the grumbling on the lack of a search feature. :)

Have you tried google? I'm positive that the mailinglist archives are being indexed.