Proposal and RFC: DAL, the Desktop Abstraction Layer

Mike Hearn mike@navi.cx
Wed Jan 19 13:11:04 PST 2005


On Wed, 2005-01-19 at 20:42 +0000, Jamie McCracken wrote:
> I equate a Dbus service with a COM server - is that correct?
> 
> If so, should they both be able to implement interfaces?

It's a good idea to avoid the word "server" when talking about COM, as
one of the many stupid mistakes it made is the way it overloads
terminology with reckless abandon. 

Basically: if I understand correctly then a DBUS service is a unique
process that has connected to the bus. A DBUS object is some C++ style
object inside that process (service) and a DBUS interface is a COM/Java
style interface on that object. Therefore you can't have interfaces on
services.

COM objects may reside in programs sometimes referred to as 'servers',
and COM objects implement interfaces. So I think this is the translation
table you want:

COM interface -> DBUS interface
COM object    -> DBUS object
COM 'server'  -> DBUS service
COM category  -> DBUS 'name'

I think the confusion arises because a DBUS name activates a *service*
not an *object*. 

In COM if you want some random object but don't care what, there are a
bunch of mechanisms you can use but they all give you back objects
(really, the IUnknown interface on an object). COM servers  are
generally more hidden/abstracted than in DBUS because they could be in-
process DLLs or whatever whereas DBUS is purely for IPC.

I wouldn't try and compare things to COM too much, DBUS serves a
fundamentally different purpose and is designed slightly differently as
a result.

thanks -mike



More information about the dbus mailing list