D BUS for real time application
Madison Kelly
linux at alteeve.com
Wed Aug 27 04:59:25 PDT 2008
DEEPESH SINGH wrote:
>
> Hi Madi,
>
> Actually we are having a application framework which is having three
> important blocks like server which provides complete library support and
> binary support for running the application then there is a application
> launcher which launches the application and the most important is the
> IPC among them which is D BUS .
>
> D BUS is responsible for every request for launching of application and
> inbetween remote procedure call and inter process communication apart
> from D BUS we are also using SOCKET for the same my observation says
> that SOCKET'S are much faster then using D BUS i may be wrong correct me
> if it is so.
>
> Apart from that what i think is if we will develop a interface for every
> kind of application like web browser,media player etc. we will make the
> system drastically fast and systematic and easy to handle coz finally
> each application requires some sort of remote procedure call or
> interdependency ,now my doubt is will it be possible to use D BUS as
> total solution or mixed of D BUS and socket , will D BUS will be able to
> provide this much throughput or not .
>
> Regards,
>
> Deepesh
From what I gather, I think D-Bus will work for you just fine.
If you want to push large amounts of data between applications, a socket
will likely still be your best bet. According to the D-Bus FAQ, a socket
file is roughly 2.5 times faster than D-Bus for raw throughput. The
reason is that D-Bus does a lot more than just pass messages; Life cycle
tracking, security and routing. This added overhead comes at a cost.
For getting messages between applications though, D-Bus is very quick.
The main benefits of D-Bus are:
- You get methods accessible to anything on the same D-Bus, regardless
of programming language. All you need to know about a published method
is what types of input parameters you need to pass it and what return
parameters to expect back, if any.
- You get life cycle tracking. D-Bus will let your application know when
a listener or service provider goes offline. You can use something like
this to trigger checks on a server and restart it after a crash, for
example.
If you do want to transfer a lot of data, you would probably be
successful at combining a D-Bus for message passing and control with
tradition sockets for file transfer. This would give you the nice
benefits and security of D-Bus with the bandwidth you want.
I would love to hear other people on this list let me know what they
think of my assessment of your needs and D-Bus. In the mean time, please
feel free to ask any more questions.
Madi
PS - What programming language(s) are you using?
More information about the dbus
mailing list