I disagree, this adds a long term support burden, complication and wastes 
resources when a more simple solution exists.  Keep in mind this is only for 
testing. We can use compile time configure flags, then a developer when 
compiling sfw can then chose which backend he wants.

Also, testing of the client/services using different backends and assuming the 
other backends are equivalent is a false assumption.  While superficially they 
work the same there are significant differences in how they operate especially 
in timing, argument passing, and even which ones spin the event loop.  Perhaps 
in time this can be resolved, but they aren't 100% identical.

Let's look at the benefits and costs of dynamic backends: 

Benefits

1. Allows services and clients to use a different back end for testing.

Costs:

1. Triples the size of the library on linux.  3 backends to choose from. (dbus, 
localsocket, unix)  

2. No other platforms have different backends that can be selected from.

3. This increases the support and maintenance burden.  Service framework in 
general supports 1 backend per platform.  For example localsocket on windows.  
If you could run dbus on windows it is not guaranteed to work.  Allowing 
services to switch results in implied support.

4. This complicates the API for testing only.

5. Clients can find but can't use services on different backends.  This is 
confusing.

6. API issue what if a request backend isn't available?  How does the 
constructor respond?

There's no advantage when new backends are added either.  For example should a 
com backend be written for windows then when it's ready it can become the 
default backend and should drop in somewhat seamlessly with the next version of 
Qt that includes it.

-Andrew

-----Original Message-----
From: development-bounces+andrew.stanley-jones=nokia....@qt-project.org 
[mailto:development-bounces+andrew.stanley-jones=nokia....@qt-project.org] On 
Behalf Of ext Thiago Macieira
Sent: Wednesday, May 02, 2012 11:01 PM
To: [email protected]
Subject: Re: [Development] Dynamic QtServiceFramework backend.

On quarta-feira, 2 de maio de 2012 13.59.02, Corentin Jabot wrote:
> The default value would be Native, corresponding on DBus where DBus is 
> available.
> 
> The library overhead should be minimal and this will not add 
> additional dependency anywhere.
> It will also made easier the add of potential future implementations, 
> like COM on windows or things like that.
> 
> If someone think this change should be made, I'm willing to work on a patch.
> Like it seems a little late for 5.0, it could be add in 5.1.
> 
> 
> What do you think ?

Sounds good!

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center
     Intel Sweden AB - Registration Number: 556189-6027
     Knarrarnäsgatan 15, 164 40 Kista, Stockholm, Sweden
_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to