Discussion:
Web service functionality in Qt5
Tomasz Siekierda
2011-08-13 13:51:04 UTC
Permalink
Hi,

I'm wondering, whether there are some people interested in seeing (even
basic) web service communication functionality in Qt5? I think that with Qt5
being heavily QML (and thus, mobile) oriented, some easy way to call web
methods, without using 3rd party libs, is needed. Currently, a lot of apps
do require frequent Internet communication (to mention one use case: stock
exachnge readers) with WSes. Even a simple implementation, capable of
getting the result fast, without subclassing anything, would be nice, IMO.
At the same time, it will leave more complicated issues to well established
packages, like GSOAP.

Now, to the main point: a couple of months ago I'v started developing a
project, which aim is to provide Qt devs with the ability to communicate
with web services. At that time, there was (and still is) GSOAP, but it was
not made "the Qt way", was IMO too complicated and not terribly intuitive.
There also was QSoap, which was more Qt-oriented, but AFAIK had some issues,
and was not recommended. Later on, while I was already hacking on my
project, I've learned about KDAB's KD Soap - which looks much better than
any mentioned above, and is definitely more advanced than my QWebService (
https://gitorious.org/qwebservice).

In QWebService, I have focused on making it intuitive, heavily Qt-based
(actually, there are no external dependencies. Communication is made using
QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can
be used both out-of-the-box, using generic classes, or by subclassing. An
automatic code generator is also included, it can take bot external URL, or
local file path to WSDL file. I'm currently developing it alone, but if
anybody is interested, feel invited to join me :) Most of the functionality
is already there, but there's still a lot room for improvements.

I'm not saying my solution has to make it into Qt, I'm perfectly fine to go
with any that will suit Qt developers' needs. I just want to raise the
subject here, since we still have a lot of time before Qt5 comes out, there
is some good stuff out there almost ready to be included, and, as I've said
- I think it's needed. What is your view here? Do we need it inside Qt, or
are we sticking to current necessity to use 3rd party stuff?

Cheers
sierdzio
Jason H
2011-08-14 17:28:30 UTC
Permalink
I had thought about this extensively, and raised the issue a couple of times in the normal qt-interest mailing list.

I'm going to paint with a wide brush, but where we left it was the following:
1. A utility to generate a class implmentation files (cpp, h) from the service description file (wsdl) containing QObject-derived class so that signals and slots are used for the call and return.

2. A runtime-generated object via QMetaObject was not preferred. 
3. A SOAP 1.2 w/MTOM+XOP is preferred, and about as complicated as ti will get. (SOAP w/MIME attachments (As opposed to base-64 encoded attachments in XML (MS XML .NET parsers has performance issues with large documents, as well as the memory implications and more complicated streaming scenarios)

I think that's the short version.




________________________________
From: Tomasz Siekierda <***@gmail.com>
To: qt5-***@qt.nokia.com
Sent: Saturday, August 13, 2011 9:51 AM
Subject: [Qt5-feedback] Web service functionality in Qt5


Hi,

I'm wondering, whether there are some people interested in seeing (even basic) web service communication functionality in Qt5? I think that with Qt5 being heavily QML (and thus, mobile) oriented, some easy way to call web methods, without using 3rd party libs, is needed. Currently, a lot of apps do require frequent Internet communication (to mention one use case: stock exachnge readers) with WSes. Even a simple implementation, capable of getting the result fast, without subclassing anything, would be nice, IMO. At the same time, it will leave more complicated issues to well established packages, like GSOAP.

Now, to the main point: a couple of months ago I'v started developing a project, which aim is to provide Qt devs with the ability to communicate with web services. At that time, there was (and still is) GSOAP, but it was not made "the Qt way", was IMO too complicated and not terribly intuitive. There also was QSoap, which was more Qt-oriented, but AFAIK had some issues, and was not recommended. Later on, while I was already hacking on my project, I've learned about KDAB's KD Soap - which looks much better than any mentioned above, and is definitely more advanced than my QWebService (https://gitorious.org/qwebservice).

In QWebService, I have focused on making it intuitive, heavily Qt-based (actually, there are no external dependencies. Communication is made using QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can be used both out-of-the-box, using generic classes, or by subclassing. An automatic code generator is also included, it can take bot external URL, or local file path to WSDL file. I'm currently developing it alone, but if anybody is interested, feel invited to join me :) Most of the functionality is already there, but there's still a lot room for improvements.

I'm not saying my solution has to make it into Qt, I'm perfectly fine to go with any that will suit Qt developers' needs. I just want to raise the subject here, since we still have a lot of time before Qt5 comes out, there is some good stuff out there almost ready to be included, and, as I've said - I think it's needed. What is your view here? Do we need it inside Qt, or are we sticking to current necessity to use 3rd party stuff?

Cheers
sierdzio
Jason H
2011-08-14 18:01:04 UTC
Permalink
Oh, one issue was server-side.

Recently there was talk of a QHttpServer class.

Could we also provide SOAP services from Qt? That is use the MOC to generate a WSDL file as well, that way Qt coouln provide and consume SOAP resources in a first-class fashion?

Of course, my preference is for REST rather than SOAP, but SOAP services aren't going away any time soon.




________________________________
From: Tomasz Siekierda <***@gmail.com>
To: qt5-***@qt.nokia.com
Sent: Saturday, August 13, 2011 9:51 AM
Subject: [Qt5-feedback] Web service functionality in Qt5


Hi,

I'm wondering, whether there are some people interested in seeing (even basic) web service communication functionality in Qt5? I think that with Qt5 being heavily QML (and thus, mobile) oriented, some easy way to call web methods, without using 3rd party libs, is needed. Currently, a lot of apps do require frequent Internet communication (to mention one use case: stock exachnge readers) with WSes. Even a simple implementation, capable of getting the result fast, without subclassing anything, would be nice, IMO. At the same time, it will leave more complicated issues to well established packages, like GSOAP.

Now, to the main point: a couple of months ago I'v started developing a project, which aim is to provide Qt devs with the ability to communicate with web services. At that time, there was (and still is) GSOAP, but it was not made "the Qt way", was IMO too complicated and not terribly intuitive. There also was QSoap, which was more Qt-oriented, but AFAIK had some issues, and was not recommended. Later on, while I was already hacking on my project, I've learned about KDAB's KD Soap - which looks much better than any mentioned above, and is definitely more advanced than my QWebService (https://gitorious.org/qwebservice).

In QWebService, I have focused on making it intuitive, heavily Qt-based (actually, there are no external dependencies. Communication is made using QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can be used both out-of-the-box, using generic classes, or by subclassing. An automatic code generator is also included, it can take bot external URL, or local file path to WSDL file. I'm currently developing it alone, but if anybody is interested, feel invited to join me :) Most of the functionality is already there, but there's still a lot room for improvements.

I'm not saying my solution has to make it into Qt, I'm perfectly fine to go with any that will suit Qt developers' needs. I just want to raise the subject here, since we still have a lot of time before Qt5 comes out, there is some good stuff out there almost ready to be included, and, as I've said - I think it's needed. What is your view here? Do we need it inside Qt, or are we sticking to current necessity to use 3rd party stuff?

Cheers
sierdzio
Tomasz Siekierda
2011-08-15 06:25:48 UTC
Permalink
I'm quite surprised how much stuff you mentioned already is in my project.
1. A utility to generate a class implmentation files (cpp, h) from the service description file (wsdl) containing QObject->derived class so that signals and slots are used for the call and return.
This is exactly what I've done, and it's almost finished. My generator
supports both synchronous (through static methods) and asynchronous
(throug signal/ slots mechanism) code generation, qmake, scons, cmake
build systems, various file structures and, just like my web method
implementation, it supports HTTP ('&' arguments), SOAP 1.0, SOAP 1.2
and JSON.
3. A SOAP 1.2 w/MTOM+XOP is preferred, and about as complicated as ti will get. (SOAP w/MIME attachments (As >opposed to base-64 encoded attachments in XML (MS XML .NET parsers has performance issues with large >documents, as well as the memory implications and more complicated streaming scenarios)
Currently I've just got basic SOAP 1.0 and 1.2 (+ JSON and HTTP, as
mentioned above) functionality, but:
a) everything is arranged so that it can be easily expanded,
b) currently I'm working just for fun and to learn while coding, so up
until now I haven't been too keen to make everything too complicated.
This can change, though :) But will need help, as I certainly lack
some knowledge and experience now.
Recently there was talk of a QHttpServer class.
Could we also provide SOAP services from Qt? That is use the MOC to generate a WSDL file as well, that way Qt >coouln provide and consume SOAP resources in a first-class fashion?
Of course, my preference is for REST rather than SOAP, but SOAP services aren't going away any time soon.
It is indeed a tempting thought. I've tried to construct my project,
so that it is easy to add server functionality, but I have not started
any implementation of it yet - I think we should do it (if indeed we
want to) together with QHttpServer guys.

Anyway, for a quick overview of my project, you can look at
https://gitorious.org/qwebservice/qwebservice/blobs/master/doc/README.txt

Cheers,
sierdzio
Oh, one issue was server-side.
Recently there was talk of a QHttpServer class.
Could we also provide SOAP services from Qt? That is use the MOC to generate a WSDL file as well, that way Qt coouln provide and consume SOAP resources in a first-class fashion?
Of course, my preference is for REST rather than SOAP, but SOAP services aren't going away any time soon.
________________________________
Sent: Saturday, August 13, 2011 9:51 AM
Subject: [Qt5-feedback] Web service functionality in Qt5
Hi,
I'm wondering, whether there are some people interested in seeing (even basic) web service communication functionality in Qt5? I think that with Qt5 being heavily QML (and thus, mobile) oriented, some easy way to call web methods, without using 3rd party libs, is needed. Currently, a lot of apps do require frequent Internet communication (to mention one use case: stock exachnge readers) with WSes. Even a simple implementation, capable of getting the result fast, without subclassing anything, would be nice, IMO. At the same time, it will leave more complicated issues to well established packages, like GSOAP.
Now, to the main point: a couple of months ago I'v started developing a project, which aim is to provide Qt devs with the ability to communicate with web services. At that time, there was (and still is) GSOAP, but it was not made "the Qt way", was IMO too complicated and not terribly intuitive. There also was QSoap, which was more Qt-oriented, but AFAIK had some issues, and was not recommended. Later on, while I was already hacking on my project, I've learned about KDAB's KD Soap - which looks much better than any mentioned above, and is definitely more advanced than my QWebService (https://gitorious.org/qwebservice).
In QWebService, I have focused on making it intuitive, heavily Qt-based (actually, there are no external dependencies. Communication is made using QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can be used both out-of-the-box, using generic classes, or by subclassing. An automatic code generator is also included, it can take bot external URL, or local file path to WSDL file. I'm currently developing it alone, but if anybody is interested, feel invited to join me :) Most of the functionality is already there, but there's still a lot room for improvements.
I'm not saying my solution has to make it into Qt, I'm perfectly fine to go with any that will suit Qt developers' needs. I just want to raise the subject here, since we still have a lot of time before Qt5 comes out, there is some good stuff out there almost ready to be included, and, as I've said - I think it's needed. What is your view here? Do we need it inside Qt, or are we sticking to current necessity to use 3rd party stuff?
Cheers
sierdzio
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Jason H
2011-08-15 11:58:02 UTC
Permalink
I've not been working with Qt for some time now, but if things go well I could be put on a Qt project which will likely need SOAP. So You might have some help in a few weeks/months.



________________________________
From: Tomasz Siekierda <***@gmail.com>
To: Jason H <***@yahoo.com>; Qt5-feedback <qt5-***@qt.nokia.com>
Sent: Monday, August 15, 2011 2:25 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5

I'm quite surprised how much stuff you mentioned already is in my project.
1. A utility to generate a class implmentation files (cpp, h) from the service description file (wsdl) containing QObject->derived class so that signals and slots are used for the call and return.
This is exactly what I've done, and it's almost finished. My generator
supports both synchronous (through static methods) and asynchronous
(throug signal/ slots mechanism) code generation, qmake, scons, cmake
build systems, various file structures and, just like my web method
implementation, it supports HTTP ('&' arguments), SOAP 1.0, SOAP 1.2
and JSON.
3. A SOAP 1.2 w/MTOM+XOP is preferred, and about as complicated as ti will get. (SOAP w/MIME attachments (As >opposed to base-64 encoded attachments in XML (MS XML .NET parsers has performance issues with large >documents, as well as the memory implications and more complicated streaming scenarios)
Currently I've just got basic SOAP 1.0 and 1.2 (+ JSON and HTTP, as
mentioned above) functionality, but:
a) everything is arranged so that it can be easily expanded,
b) currently I'm working just for fun and to learn while coding, so up
until now I haven't been too keen to make everything too complicated.
This can change, though :) But  will need help, as I certainly lack
some knowledge and experience now.
Recently there was talk of a QHttpServer class.
Could we also provide SOAP services from Qt? That is use the MOC to generate a WSDL file as well, that way Qt >coouln provide and consume SOAP resources in a first-class fashion?
Of course, my preference is for REST rather than SOAP, but SOAP services aren't going away any time soon.
It is indeed a tempting thought. I've tried to construct my project,
so that it is easy to add server functionality, but I have not started
any implementation of it yet - I think we should do it (if indeed we
want to) together with QHttpServer guys.

Anyway, for a quick overview of my project, you can look at
https://gitorious.org/qwebservice/qwebservice/blobs/master/doc/README.txt

Cheers,
sierdzio
Oh, one issue was server-side.
Recently there was talk of a QHttpServer class.
Could we also provide SOAP services from Qt? That is use the MOC to generate a WSDL file as well, that way Qt coouln provide and consume SOAP resources in a first-class fashion?
Of course, my preference is for REST rather than SOAP, but SOAP services aren't going away any time soon.
________________________________
Sent: Saturday, August 13, 2011 9:51 AM
Subject: [Qt5-feedback] Web service functionality in Qt5
Hi,
I'm wondering, whether there are some people interested in seeing (even basic) web service communication functionality in Qt5? I think that with Qt5 being heavily QML (and thus, mobile) oriented, some easy way to call web methods, without using 3rd party libs, is needed. Currently, a lot of apps do require frequent Internet communication (to mention one use case: stock exachnge readers) with WSes. Even a simple implementation, capable of getting the result fast, without subclassing anything, would be nice, IMO. At the same time, it will leave more complicated issues to well established packages, like GSOAP.
Now, to the main point: a couple of months ago I'v started developing a project, which aim is to provide Qt devs with the ability to communicate with web services. At that time, there was (and still is) GSOAP, but it was not made "the Qt way", was IMO too complicated and not terribly intuitive. There also was QSoap, which was more Qt-oriented, but AFAIK had some issues, and was not recommended. Later on, while I was already hacking on my project, I've learned about KDAB's KD Soap - which looks much better than any mentioned above, and is definitely more advanced than my QWebService (https://gitorious.org/qwebservice).
In QWebService, I have focused on making it intuitive, heavily Qt-based (actually, there are no external dependencies. Communication is made using QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can be used both out-of-the-box, using generic classes, or by subclassing. An automatic code generator is also included, it can take bot external URL, or local file path to WSDL file. I'm currently developing it alone, but if anybody is interested, feel invited to join me :) Most of the functionality is already there, but there's still a lot room for improvements.
I'm not saying my solution has to make it into Qt, I'm perfectly fine to go with any that will suit Qt developers' needs. I just want to raise the subject here, since we still have a lot of time before Qt5 comes out, there is some good stuff out there almost ready to be included, and, as I've said - I think it's needed. What is your view here? Do we need it inside Qt, or are we sticking to current necessity to use 3rd party stuff?
Cheers
sierdzio
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Peter Hartmann
2011-08-15 12:28:05 UTC
Permalink
(the reply might not show up in thread, I joined the mailing list after
this message was posted)

@Tomasz:

I like your idea regarding a SOAP code generator approach, here some
thoughts:

* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.

* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.

Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...

Regards,

Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
qt next
2011-08-15 12:33:55 UTC
Permalink
@Tomasz : Do you plan to release QWebService with another licence : Lgpl
?MIT? BSD? to allow commercial uses ?
Post by Peter Hartmann
(the reply might not show up in thread, I joined the mailing list after
this message was posted)
I like your idea regarding a SOAP code generator approach, here some
* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.
* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.
Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...
Regards,
Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Konstantin Tokarev
2011-08-15 12:43:41 UTC
Permalink
@Tomasz : Do you plan to release QWebService with another licence : Lgpl ?MIT? BSD? to allow commercial uses ?
FYI: While you are using GPL'ed QWebService (or derived products) on servers of your company GPL does not restrict your rights (it's not a redistribution even if you service thousands of people who pay money for it). You don't have to show your source code to anyone and even can use modified QWebService.

Don't confuse GPL and AGPL.
--
Regards,
Konstantin
Jason H
2011-08-15 13:00:32 UTC
Permalink
Various comments:

- I would prefer it to be LGPL so it might be included in Qt proper...
- Someone asked about not using QtXML and just stream reader classes. I agree for the run-time stuff it would be nice to use the stream stuff in QtCore, but I don't see the wsdl utility usign QtXML being a big deal. 
- A purist might want to see it not require networking (just provide request serialization) so you could do SOAP over email (http://www.w3.org/TR/soap12-email) and other exotic bindings (RPC, etc)


- I haven't had time to check this out in detail, but I am excited about it and I will attempt to enhance it rather than roll my own again. For contributions, I'll share what I do, but I'd prefer my work being LGPL licensed.



________________________________
From: qt next <***@gmail.com>
To: qt5-***@qt.nokia.com
Cc: ***@gmail.com
Sent: Monday, August 15, 2011 8:33 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5


@Tomasz : Do you plan to release QWebService with another licence : Lgpl ?MIT? BSD? to allow commercial uses ?




2011/8/15 Peter Hartmann <***@nokia.com>

(the reply might not show up in thread, I joined the mailing list after
Post by Peter Hartmann
this message was posted)
I like your idea regarding a SOAP code generator approach, here some
* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.
* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.
Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...
Regards,
Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Konstantin Tokarev
2011-08-15 14:27:18 UTC
Permalink
_______________________________________________
Qt5-feedback mailing list
Qt5-***@qt.nokia.com
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Tomasz Siekierda
2011-08-15 14:28:30 UTC
Permalink
OK thank you all for your comments, I'll try to address them all.

1. I AM using QXmlStreamReader to read WSDL files - I just assumed
it's in QXML module without checking, so - my bad. It would now seem
that XML module is not required by my project.

2. Licence.
I am open for suggestions here, if you prefer LGPL, so it could be.
Since AFAIK I am currently the only user of this code, I can change it
without any problems caused to anybody. Mind you, only a part of the
project is a library (QWebService), the second part is the WSDL
converter, which is - obviously - a console app. Would that be a
problem? I'm not an expert when it comes to licences.

3. @Peter Hartmann - it's actually my first project using XML in Qt, I
would certainly like to learn more, but I cannot guarantee anything
extraordinary now. Partially that is why I post info about it here -
if you like it, and want to see it not just as a hobbyist project, but
as part of Qt, you'll have to help me - especially in a) licencing
issues, b) more hardcore web service details (I lack experience in big
WS projects, too).

4. Regarding providing server functionality. Just to mention - it
would be a major endeavor, as we'll have to implement various tricky
features like BPEL4WS, and use of still not ready QtServer
functionality.

5. Since talks are getting more serious, another point to consider is
whether we like to see QWebService as a major platform for accessing
any WS, or just a simple reader for out-of-the-box use (this approach
will make other commercial packages happy :) ). What I mean here is,
say: you are writing a Qt app for a mobile device, and need to make a
simple query - for example, get current Euro to Dollar ratio. You
don't have to write much of your own code, nor use big monsters like
GSOAP, you simply fire a QWebMethod::sendMessage() and parse the reply
on your own. This is possible right now, as my current implementation
does that. I am extending the functionality, of course, but if we were
to make it really full-featured web service suite, it might require
different approach. Or maybe not? Just a thought.

sierdzio.
Post by Jason H
- I would prefer it to be LGPL so it might be included in Qt proper...
- Someone asked about not using QtXML and just stream reader classes. I
agree for the run-time stuff it would be nice to use the stream stuff in
QtCore, but I don't see the wsdl utility usign QtXML being a big deal.
- A purist might want to see it not require networking (just provide request
serialization) so you could do SOAP over email
(http://www.w3.org/TR/soap12-email) and other exotic bindings (RPC, etc)
- I haven't had time to check this out in detail, but I am excited about it
and I will attempt to enhance it rather than roll my own again. For
contributions, I'll share what I do, but I'd prefer my work being LGPL
licensed.
________________________________
Sent: Monday, August 15, 2011 8:33 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
@Tomasz : Do you plan to release QWebService with another licence : Lgpl
?MIT? BSD? to allow commercial uses ?
(the reply might not show up in thread, I joined the mailing list after
this message was posted)
I like your idea regarding a SOAP code generator approach, here some
* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.
* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.
Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...
Regards,
Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Tomasz Siekierda
2011-08-15 14:37:54 UTC
Permalink
Oh yeah, I forgot about REST WSes. All I did in REST was some web site
for an University in Poland, and I did that in Ruby on Rails (I would
recommend anyone to try RoR, by the way, beautiful framework). So I -
again - lack experience here. Myself, I'm positive about including
REST, although currently I am more focused on polishing current code.
Post by Tomasz Siekierda
OK thank you all for your comments, I'll try to address them all.
1. I AM using QXmlStreamReader to read WSDL files - I just assumed
it's in QXML module without checking, so - my bad. It would now seem
that XML module is not required by my project.
2. Licence.
I am open for suggestions here, if you prefer LGPL, so it could be.
Since AFAIK I am currently the only user of this code, I can change it
without any problems caused to anybody. Mind you, only a part of the
project is a library (QWebService), the second part is the WSDL
converter, which is - obviously - a console app. Would that be a
problem? I'm not an expert when it comes to licences.
would certainly like to learn more, but I cannot guarantee anything
extraordinary now. Partially that is why I post info about it here -
if you like it, and want to see it not just as a hobbyist project, but
as part of Qt, you'll have to help me - especially in a) licencing
issues, b) more hardcore web service details (I lack experience in big
WS projects, too).
4. Regarding providing server functionality. Just to mention - it
would be a major endeavor, as we'll have to implement various tricky
features like BPEL4WS, and use of still not ready QtServer
functionality.
5. Since talks are getting more serious, another point to consider is
whether we like to see QWebService as a major platform for accessing
any WS, or just a simple reader for out-of-the-box use (this approach
will make other commercial packages happy :) ). What I mean here is,
say: you are writing a Qt app for a mobile device, and need to make a
simple query - for example, get current Euro to Dollar ratio. You
don't have to write much of your own code, nor use big monsters like
GSOAP, you simply fire a QWebMethod::sendMessage() and parse the reply
on your own. This is possible right now, as my current implementation
does that. I am extending the functionality, of course, but if we were
to make it really full-featured web service suite, it might require
different approach. Or maybe not? Just a thought.
sierdzio.
Post by Jason H
- I would prefer it to be LGPL so it might be included in Qt proper...
- Someone asked about not using QtXML and just stream reader classes. I
agree for the run-time stuff it would be nice to use the stream stuff in
QtCore, but I don't see the wsdl utility usign QtXML being a big deal.
- A purist might want to see it not require networking (just provide request
serialization) so you could do SOAP over email
(http://www.w3.org/TR/soap12-email) and other exotic bindings (RPC, etc)
- I haven't had time to check this out in detail, but I am excited about it
and I will attempt to enhance it rather than roll my own again. For
contributions, I'll share what I do, but I'd prefer my work being LGPL
licensed.
________________________________
Sent: Monday, August 15, 2011 8:33 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
@Tomasz : Do you plan to release QWebService with another licence : Lgpl
?MIT? BSD? to allow commercial uses ?
(the reply might not show up in thread, I joined the mailing list after
this message was posted)
I like your idea regarding a SOAP code generator approach, here some
* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.
* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.
Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...
Regards,
Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Jason H
2011-08-15 16:19:24 UTC
Permalink
I was recently informed:

Qt proper requires licensing under the Contribution License Agreement. You
must not included LGPL code from third-parties if you wish to submit under the
CLA.

Since I'd like to see this a regular part of Qt, I suggest you use that license. :-) We'll also need a through test suite to get it into Qt.

I don't see how servers should be that much harder. Once you have the proxy, the client would map a call to the proxy's slotfor network comms. The sever would map the network comms to the proxy's slot, then the proxy object would map to one or more actual objects.




________________________________
From: Tomasz Siekierda <***@gmail.com>
To: Jason H <***@yahoo.com>
Cc: qt next <***@gmail.com>; "qt5-***@qt.nokia.com" <qt5-***@qt.nokia.com>
Sent: Monday, August 15, 2011 10:28 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5

OK thank you all for your comments, I'll try to address them all.

1. I AM using QXmlStreamReader to read WSDL files - I just assumed
it's in QXML module without checking, so - my bad. It would now seem
that XML module is not required by my project.

2. Licence.
I am open for suggestions here, if you prefer LGPL, so it could be.
Since AFAIK I am currently the only user of this code, I can change it
without any problems caused to anybody. Mind you, only a part of the
project is a library (QWebService), the second part is the WSDL
converter, which is - obviously - a console app. Would that be a
problem? I'm not an expert when it comes to licences.

3. @Peter Hartmann - it's actually my first project using XML in Qt, I
would certainly like to learn more, but I cannot guarantee anything
extraordinary now. Partially that is why I post info about it here -
if you like it, and want to see it not just as a hobbyist project, but
as part of Qt, you'll have to help me - especially in a) licencing
issues, b) more hardcore web service details (I lack experience in big
WS projects, too).

4. Regarding providing server functionality. Just to mention - it
would be a major endeavor, as we'll have to implement various tricky
features like BPEL4WS, and use of still not ready QtServer
functionality.

5. Since talks are getting more serious, another point to consider is
whether we like to see QWebService as a major platform for accessing
any WS, or just a simple reader for out-of-the-box use (this approach
will make other commercial packages happy :) ). What I mean here is,
say: you are writing a Qt app for a mobile device, and need to make a
simple query - for example, get current Euro to Dollar ratio. You
don't have to write much of your own code, nor use big monsters like
GSOAP, you simply fire a QWebMethod::sendMessage() and parse the reply
on your own. This is possible right now, as my current implementation
does that. I am extending the functionality, of course, but if we were
to make it really full-featured web service suite, it might require
different approach. Or maybe not? Just a thought.

sierdzio.
Post by Jason H
- I would prefer it to be LGPL so it might be included in Qt proper...
- Someone asked about not using QtXML and just stream reader classes. I
agree for the run-time stuff it would be nice to use the stream stuff in
QtCore, but I don't see the wsdl utility usign QtXML being a big deal.
- A purist might want to see it not require networking (just provide request
serialization) so you could do SOAP over email
(http://www.w3.org/TR/soap12-email) and other exotic bindings (RPC, etc)
- I haven't had time to check this out in detail, but I am excited about it
and I will attempt to enhance it rather than roll my own again. For
contributions, I'll share what I do, but I'd prefer my work being LGPL
licensed.
________________________________
Sent: Monday, August 15, 2011 8:33 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
@Tomasz : Do you plan to release QWebService with another licence : Lgpl
?MIT? BSD? to allow commercial uses ?
(the reply might not show up in thread, I joined the mailing list after
this message was posted)
I like your idea regarding a SOAP code generator approach, here some
* regarding your WSDL-to-C++ generator: Are you planning to access the
Qt schema data model in xmlpatterns (src/xmlpatterns/schema/)? That
might be the way to go, so you get a Qt representation of the XML schema
portion of a WSDL file for free. Accessing the functionality might be
tricky though, you would need to include private header files etc.
* Using Qt XML module: How about using QXmlStream* classes in the core
module? They are much more memory efficient, but operate on a lower
layer (like SAX), but in the case of SOAP where XML messages can become
quite big you might not want to have the whole DOM in memory.
Btw. there will be a talk titled "Qt Networking - Web Services" at the
DevDays 2011 (see http://qt.nokia.com/qtdevdays2011/techtrack), but that
talk will be targeting REST based Web Services...
Regards,
Peter
--
Qt Developer Days 2011 – REGISTER NOW!
October 24 – 26, Munich
November 29 – December 1, San Francisco
Learn more and Register at http://qt.nokia.com/qtdevdays2011
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Tomasz Siekierda
2011-08-15 19:22:53 UTC
Permalink
According to http://developer.qt.nokia.com/wiki/Qt_Contribution_Guidelines
CLA applies to code created in a local Qt branch. My project
(currently) is stand-alone, so it probably can be left as LGPL (can
some Troll confirm that, please?). Also, can does LGPL apply to
console apps like my wsdlConverter?

Is it just me and Jason, who want it in Qt itself? Also, Jason,
correct me if I am wrong, but sending SOAP via email still requires
networking, doesn't it?

For those, who don't want to dive into code straight away, I've
created some introductory video:


Good night to you all,
sierdzio
Post by Jason H
Qt proper requires licensing under the Contribution License Agreement. You
must not included LGPL code from third-parties if you wish to submit under the
CLA.
Since I'd like to see this a regular part of Qt, I suggest you use that
license. :-) We'll also need a through test suite to get it into Qt.
I don't see how servers should be that much harder. Once you have the proxy,
the client would map a call to the proxy's slotfor network comms. The sever
would map the network comms to the proxy's slot, then the proxy object would
map to one or more actual objects.
Konstantin Tokarev
2011-08-15 19:28:09 UTC
Permalink
Post by Tomasz Siekierda
According to http://developer.qt.nokia.com/wiki/Qt_Contribution_Guidelines
CLA applies to code created in a local Qt branch. My project
(currently) is stand-alone, so it probably can be left as LGPL (can
some Troll confirm that, please?). Also, can does LGPL apply to
console apps like my wsdlConverter?
Is it just me and Jason, who want it in Qt itself? Also, Jason,
correct me if I am wrong, but sending SOAP via email still requires
networking, doesn't it?
But it might not require QtNetwork.
--
Regards,
Konstantin
Jason H
2011-08-15 19:37:58 UTC
Permalink
Right. MAPI (Mail API) could come in on exotic devices, like devices without a constant network connection. The mail queue would be a trivial buffer. Also, I figure being able to serialize the comms to a file rather than a socket could aid in testing (canned files) or debugging.



________________________________
From: Konstantin Tokarev <***@yandex.ru>
To: Tomasz Siekierda <***@gmail.com>
Cc: Jason H <***@yahoo.com>; ***@gmail.com; qt5-***@qt.nokia.com; ***@viroteck.net; ***@nokia.com
Sent: Monday, August 15, 2011 3:28 PM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
Post by Tomasz Siekierda
According to http://developer.qt.nokia.com/wiki/Qt_Contribution_Guidelines
CLA applies to code created in a local Qt branch. My project
(currently) is stand-alone, so it probably can be left as LGPL (can
some Troll confirm that, please?). Also, can does LGPL apply to
console apps like my wsdlConverter?
Is it just me and Jason, who want it in Qt itself? Also, Jason,
correct me if I am wrong, but sending SOAP via email still requires
networking, doesn't it?
But it might not require QtNetwork.
--
Regards,
Konstantin
Prashanth Udupa
2011-08-16 04:09:09 UTC
Permalink
Hi Tomaz,

Check out: http://www.vcreatelogic.com/docs/gcf-2.5.0/html/gcfappserver.html.
Using this one can write server components and host them on a server
(GCFApplicationServer) written using Qt. GCFApplicationServer works with
Apache / IIS etc; which means that it does not have to re implement all of
the web-server functionality.

It does not support SOAP, but it has its own XML packet format for message
exchange. There is also a JavaScript libary that helps make function calls
(AJAX style) on services hosted in GCFApplicationServer. In addition to
that, native Qt applications can easily issue function calls on the services
hosted in GCFApplicationServer as well. WebServices can also be accessed
using CleanURLs (
http://blog.vcreatelogic.com/2011/08/gcfapplicationserver-and-clean-urls/)
Future
versions will also have support for JSON packet format.

/ Prashanth
Post by Tomasz Siekierda
Hi,
I'm wondering, whether there are some people interested in seeing (even
basic) web service communication functionality in Qt5? I think that with Qt5
being heavily QML (and thus, mobile) oriented, some easy way to call web
methods, without using 3rd party libs, is needed. Currently, a lot of apps
do require frequent Internet communication (to mention one use case: stock
exachnge readers) with WSes. Even a simple implementation, capable of
getting the result fast, without subclassing anything, would be nice, IMO.
At the same time, it will leave more complicated issues to well established
packages, like GSOAP.
Now, to the main point: a couple of months ago I'v started developing a
project, which aim is to provide Qt devs with the ability to communicate
with web services. At that time, there was (and still is) GSOAP, but it was
not made "the Qt way", was IMO too complicated and not terribly intuitive.
There also was QSoap, which was more Qt-oriented, but AFAIK had some issues,
and was not recommended. Later on, while I was already hacking on my
project, I've learned about KDAB's KD Soap - which looks much better than
any mentioned above, and is definitely more advanced than my QWebService (
https://gitorious.org/qwebservice).
In QWebService, I have focused on making it intuitive, heavily Qt-based
(actually, there are no external dependencies. Communication is made using
QNAM, XML parsing - Qt XML module, everything is QDoc docummented). It can
be used both out-of-the-box, using generic classes, or by subclassing. An
automatic code generator is also included, it can take bot external URL, or
local file path to WSDL file. I'm currently developing it alone, but if
anybody is interested, feel invited to join me :) Most of the functionality
is already there, but there's still a lot room for improvements.
I'm not saying my solution has to make it into Qt, I'm perfectly fine to go
with any that will suit Qt developers' needs. I just want to raise the
subject here, since we still have a lot of time before Qt5 comes out, there
is some good stuff out there almost ready to be included, and, as I've said
- I think it's needed. What is your view here? Do we need it inside Qt, or
are we sticking to current necessity to use 3rd party stuff?
Cheers
sierdzio
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
--
*Prashanth N Udupa

VCreate Logic Pvt. Ltd.
#177, 50 Feet Road, 5th Cross,
Opp Avalahalli BDA Park, Girinagar,
Banashankari III Stage, Bangalore,
Karnataka, India, 560085

Phone: 99028 88934
Personal URL: http://www.prashanthudupa.com
*
Tomasz Siekierda
2011-08-16 19:04:35 UTC
Permalink
Another small update from me, hope you don't mind.

@Prashanth - very interesting project, seems powerful. But - we are
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.

@everyone - not to flood Qt5-feedback too much, I've created a GDoc
with current feature requests and TODO's http://goo.gl/L1C6X, it's
editable by anybody, so feel free to put some new ideas there (I've
put included most already noted here on Qt5-feedback). Would probably
be better to make a separate mailing list, but I'm too lazy for that,
and it's probably not needed yet.

Today, I've (IMPORTANT) changed licence back to LGPL 2.1 (both on
Gitorious project page and in source), implemented another switch for
WSDL converter, did some other optimizations and fixes.

Cheerio,
sierdzio
Prashanth Udupa
2011-08-17 12:29:18 UTC
Permalink
Hi Tomasz,
Post by Tomasz Siekierda
@Prashanth - very interesting project, seems powerful. But - we are
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.
Yes. We can support multiple message formats in GCF. Currently we have a
custom XML message format. We will be supporting JSON soon. It would not be
impossible to support SOAP.

So, in theory - we should be able to mix web-services written using GCF/Qt
with other web-services by using SOAP and/or JSON.

Best Regards,
Prashanth
Jason H
2011-08-17 13:34:13 UTC
Permalink
I think that any RPC/JSON(JavaScript)/SOAP(XML)/Python/QtDataStream etc serialization work should be done as an independent or reusuable work. I can see converting to/from a QObject to any format as useful beyond web services. If you are going to support XML and JSON, then might as well eave room for other formats as well...



________________________________
From: Prashanth Udupa <***@vcreatelogic.com>
To: Tomasz Siekierda <***@gmail.com>
Cc: Qt5-feedback <qt5-***@qt.nokia.com>; qt next <***@gmail.com>; Robin Burchell <***@viroteck.net>; Konstantin Tokarev <***@yandex.ru>; Jason H <***@yahoo.com>; Peter Hartmann <***@nokia.com>
Sent: Wednesday, August 17, 2011 8:29 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5


Hi Tomasz,
 
@Prashanth - very interesting project, seems powerful. But - we are
Post by Tomasz Siekierda
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.
Yes. We can support multiple message formats in GCF. Currently we have a custom XML message format. We will be supporting JSON soon. It would not be impossible to support SOAP. 

So, in theory - we should be able to mix web-services written using GCF/Qt with other web-services by using SOAP and/or JSON.

Best Regards,
Prashanth
Tomasz Siekierda
2011-08-17 13:56:33 UTC
Permalink
@QWebService idea in general - I've read IBM's view on RESTful WSes,
and it seems not particurarly hard to implement on top of existing
QWebMethod code. I'll try doing that soon. I'll also investigate usage
of XmlPatterns in some experimental branch, as it will require major
changes in QWsdl. In the meantime, I've still got other important
features to add to the project, as specified in http://goo.gl/L1C6X,
and in docs (BTW, Gitorious' wiki is also fully editable, feel free to
use it, too). And, as I learn from today's feedback topics, QUrl will
also change, and I use it a lot.
Anyway, I've introduced another switch, and many bug fixes into the code today.

@Jason - there was some talk on serialization on Qt5-feedback, but I
don't remember the results. True, that would be a useful feature
(although, to be honest, AFAIK it is at least partially done even now
- just see how QSettings stores various data. And QSettings getts
stuff from QVariant).

@Prashanth - right then, welcome aboard, I guess. As I've mentioned
before, I still have lots to do in current (reading, converting) code,
so I won't do much (anything, in fact, at least in the coming few
weeks) in terms of server functionality. If you want to, you can start
doing that yourself. You probably have to contact guys working on
QService, and arrange some common ground with them (QtService was
proposed in June by BRM - bm_witness at yahoo.com, on this mailing
list).

To say again - any help would be greatly appreciated, not only by me,
but possibly by community at large :)
Post by Jason H
I think that any RPC/JSON(JavaScript)/SOAP(XML)/Python/QtDataStream etc
serialization work should be done as an independent or reusuable work. I can
see converting to/from a QObject to any format as useful beyond web
services. If you are going to support XML and JSON, then might as well eave
room for other formats as well...
________________________________
Sent: Wednesday, August 17, 2011 8:29 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
Hi Tomasz,
@Prashanth - very interesting project, seems powerful. But - we are
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.
Yes. We can support multiple message formats in GCF. Currently we have a
custom XML message format. We will be supporting JSON soon. It would not be
impossible to support SOAP.
So, in theory - we should be able to mix web-services written using GCF/Qt
with other web-services by using SOAP and/or JSON.
Best Regards,
Prashanth
Jason H
2011-08-17 14:13:41 UTC
Permalink
I don't have the link for the IBM article, but most of my REST interface code looks like sprintfs or QString().arg().arg(), etc. I just love the simplicity. Engineers tend to love it but committees don't. That's why I usually end up writing SOAP wrappers for REST services.


I'm hoping to be assigned back to a Qt project in the coming weeks. If that happens I'll definitely see what I can contribute.



________________________________
From: Tomasz Siekierda <***@gmail.com>
To: Jason H <***@yahoo.com>
Cc: Prashanth Udupa <***@vcreatelogic.com>; Qt5-feedback <qt5-***@qt.nokia.com>; qt next <***@gmail.com>; Robin Burchell <***@viroteck.net>; Konstantin Tokarev <***@yandex.ru>; Peter Hartmann <***@nokia.com>
Sent: Wednesday, August 17, 2011 9:56 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5

@QWebService idea in general - I've read IBM's view on RESTful WSes,
and it seems not particurarly hard to implement on top of existing
QWebMethod code. I'll try doing that soon. I'll also investigate usage
of XmlPatterns in some experimental branch, as it will require major
changes in QWsdl. In the meantime, I've still got other important
features to add to the project, as specified in http://goo.gl/L1C6X,
and in docs (BTW, Gitorious' wiki is also fully editable, feel free to
use it, too). And, as I learn from today's feedback topics, QUrl will
also change, and I use it a lot.
Anyway, I've introduced another switch, and many bug fixes into the code today.

@Jason - there was some talk on serialization on Qt5-feedback, but I
don't remember the results. True, that would be a useful feature
(although, to be honest, AFAIK it is at least partially done even now
- just see how QSettings stores various data. And QSettings getts
stuff from QVariant).

@Prashanth - right then, welcome aboard, I guess. As I've mentioned
before, I still have lots to do in current (reading, converting) code,
so I won't do much (anything, in fact, at least in the coming few
weeks) in terms of server functionality. If you want to, you can start
doing that yourself. You probably have to contact guys working on
QService, and arrange some common ground with them (QtService was
proposed in June by BRM - bm_witness at yahoo.com, on this mailing
list).

To say again - any help would be greatly appreciated, not only by me,
but possibly by community at large :)
Post by Jason H
I think that any RPC/JSON(JavaScript)/SOAP(XML)/Python/QtDataStream etc
serialization work should be done as an independent or reusuable work. I can
see converting to/from a QObject to any format as useful beyond web
services. If you are going to support XML and JSON, then might as well eave
room for other formats as well...
________________________________
Sent: Wednesday, August 17, 2011 8:29 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
Hi Tomasz,
@Prashanth - very interesting project, seems powerful. But - we are
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.
Yes. We can support multiple message formats in GCF. Currently we have a
custom XML message format. We will be supporting JSON soon. It would not be
impossible to support SOAP.
So, in theory - we should be able to mix web-services written using GCF/Qt
with other web-services by using SOAP and/or JSON.
Best Regards,
Prashanth
BRM
2011-08-17 18:12:57 UTC
Permalink
Yes, thanks for the reminder. Things have been busy at work and with a new baby at home, I've had some trouble finding time to work on it.
Rest assured I do still plan on doing the work - it's just been very slow, and I've still got to get more familiar with git (recommendations welcome).

Ben



----- Original Message -----
Post by Jason H
Sent: Wednesday, August 17, 2011 9:56 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
@QWebService idea in general - I've read IBM's view on RESTful WSes,
and it seems not particurarly hard to implement on top of existing
QWebMethod code. I'll try doing that soon. I'll also investigate usage
of XmlPatterns in some experimental branch, as it will require major
changes in QWsdl. In the meantime, I've still got other important
features to add to the project, as specified in http://goo.gl/L1C6X,
and in docs (BTW, Gitorious' wiki is also fully editable, feel free to
use it, too). And, as I learn from today's feedback topics, QUrl will
also change, and I use it a lot.
Anyway, I've introduced another switch, and many bug fixes into the code today.
@Jason - there was some talk on serialization on Qt5-feedback, but I
don't remember the results. True, that would be a useful feature
(although, to be honest, AFAIK it is at least partially done even now
- just see how QSettings stores various data. And QSettings getts
stuff from QVariant).
@Prashanth - right then, welcome aboard, I guess. As I've mentioned
before, I still have lots to do in current (reading, converting) code,
so I won't do much (anything, in fact, at least in the coming few
weeks) in terms of server functionality. If you want to, you can start
doing that yourself. You probably have to contact guys working on
QService, and arrange some common ground with them (QtService was
proposed in June by BRM - bm_witness at yahoo.com, on this mailing
list).
To say again - any help would be greatly appreciated, not only by me,
but possibly by community at large :)
Post by Jason H
I think that any RPC/JSON(JavaScript)/SOAP(XML)/Python/QtDataStream etc
serialization work should be done as an independent or reusuable work. I
can
Post by Jason H
see converting to/from a QObject to any format as useful beyond web
services. If you are going to support XML and JSON, then might as well eave
room for other formats as well...
________________________________
Sent: Wednesday, August 17, 2011 8:29 AM
Subject: Re: [Qt5-feedback] Web service functionality in Qt5
Hi Tomasz,
@Prashanth - very interesting project, seems powerful. But - we are
talking about web service functionality, which means that apps written
not only in Qt (but indeed, any other language/ framework) would need
to contact it flawlessly (which in turn means communication using
established protocols, like SOAP). Is that possible in GCF? I'm not
saying no, though - I'll need to read a bit more about it.
Yes. We can support multiple message formats in GCF. Currently we have a
custom XML message format. We will be supporting JSON soon. It would not be
impossible to support SOAP.
So, in theory - we should be able to mix web-services written using GCF/Qt
with other web-services by using SOAP and/or JSON.
Best Regards,
Prashanth
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Tomasz Siekierda
2011-08-20 17:28:02 UTC
Permalink
After a few day's break in communication, I come back with some big updates.
Before I post some info on what has changed in source, a few other issues:

1. One thing I forgot to talk about all this time - @Peter Hartmann,
about Qt Dev Days and WS talk.
Good to hear it's going to be there, but for me the whole party is a
bit pricey (I'm just a student).
I'd like to come, and I'm still thinking about it (especially because
I've some friends there, which may
lower accommodation costs), but most probably I won't. Hope there will
be some videos available afterwards.

2. I have to do some real testing, and there is still lot to do, but
even now, I would be glad to hear some feedback
on the API (it's intuitiveness, if there is any, naming etc.),
especially concerning QWebMethod
(and QWebServiceMethod I recently brought to life). Also, do we need
private classes, which are so popular inside Qt4 sources?
For example, parameter setting (generic) is currently done by means of
QMap<QString, QVariant>, which
might be a bit tricky, especially for RESTful WSes (today I've
introduced an override in sendMessage()
to counter that, but I feel there is a need for - for example -
QString parameter setter).

3. Also, a bit more into the future, some help will be needed in
proper "packaging" - how to arrange
files, directories, .pro files, where to put them in cloned Qt source
and make properly integrate with
the rest of it (if you indeed want it in Qt).

4. Today, I've pushed a commit tagged as v0.4.0. In the recent week, I
made major changes to the project.
In the upcoming days, I'll probably start writing more complete and
QtTest-based tests (and expand QWsdl,
which needs new functionality badly).
Here's what's been happening (only major changes; for minor ones, see
changelog on Gitorious):
 - added RESTfulness to QWebMethod,
 - added RESTfulness to WSDL converter,
 - added --subclass, --compact-mode, --xml, --rest= switches to WSDL
converter (plus suffix switches),
 - added some convenience methods to QWebMethod and WSDL converter
(including some getters I forgot about earlier),
 - added additional sanity checks for flags in WSDL converter and QWebMethod,
 - made QWebMethod a bit more abstract, moved "specific" code to
QWebServiceMethod. QWebMethod is now easier to subclass
   and easier to use in a more generic way,
 - updated all the code to honour Qt Coding Convention,
 - expanded QDoc and README descriptions,
 - changed #includes to be more specific (they link to .h files),
 - some code cleaning,
 - plus numerous bug fixes and other minor changes.

Good weekend to you all,
sierdzio
Tomasz Siekierda
2011-09-07 10:45:11 UTC
Permalink
Time for another QWebService update, including a merge request announcement.

I've done writing some tests and examples, as well as updating the
whole API and WSDL converter. Since the last message on qt5-feedback,
there's been an awful lot of updates, I won't list them all here (they
are available in both changelog and commit log). The example involves
invoking QtDeveloperNetwork API, message is being sent using 3 lines
of code (although actually doing it with 1 line is possible).

The thing is, that I feel the code - although it certainly still has
to get some improvements - is merge ready (to put it simply - it
works. Tests work. Example app works, too. Everything can be used
out-of-the-box, and the most useful part - QWebMethod - is quite
feature-rich now). My argument is quite similiar to recent one from
Lars, and revolves around the notion that as soon as it's merged,
people can start contributing in a "native" way, that is inside qt5
git repo (if they want to, since the response was not what I would
call huge).

Now, on with technicalities:
- I put all QWebService code into qtbase/src/network/access (very
convenient, as it uses QNAM, which is in the very same folder. On the
other hand, it is significally more high-level than QNAM, so I'm not
100% sure it's a good idea),
- WSDL converter went into qttools/src/qtwsdlconverter,
- example app was put in qtbase/examples/qtdevelopernetwork,
- tests are in qtbase/tests/auto/{qwebmethod, qwebservicemethod,
qwebservice, qwsdl}.

I am currently working on that in clones of qtbase (QWebService lib)
and qttools (WSDL converter). I'll probably fill merge requests
soon(-ish), as the initial copying and adjustments are already
finished. Repos can be found at:
- (QWebService) https://gitorious.org/~sierdzio/qt/sierdzio-qtbase-qwebservice
- (WSDL converter)
https://gitorious.org/~sierdzio/qt/sierdzio-qttools-qwebservice

As a reminder, my main development repo for QWebService is still at
https://gitorious.org/qwebservice. Just as usual, any feedback would
be greatly appreciated. Regardless of whether QWebService will make it
into Qt5 or not, the package is currently fully usable and can be used
as a separate product. Enjoy, if you wish to :) Here's a small teaser
of the afore mentioned QtDevNet example:


Cheers,
sierdzio
Tomasz Siekierda
2011-09-23 14:10:37 UTC
Permalink
Hi,
again, long time no see, but I'm coming back with more or less good
news, and some questions.

I've filled merge request (#51) for QWebService (converter is
temporarily waiting), and got some feedback from Thiago. He did
propose to move my sources from QtNetwork into an add-on. I find this
idea very good, but wish to enquiry here. What is your view on that?
(if anyone happens to have any, that is).

In other news, sources got updated to v0.5.0, with many improvements -
most behind the scenes, but there are also some API updates. Repos can
be found at:
 - (main repo, separate from Qt) https://gitorious.org/qwebservice
 - (merge request) https://qt.gitorious.org/qt/qtbase/merge_requests/51
 - (***@Qt)
https://gitorious.org/~sierdzio/qt/sierdzio-qtbase-qwebservice
 - (WSDL ***@Qt)
https://gitorious.org/~sierdzio/qt/sierdzio-qttools-qwebservice

Just as usual, any feedback would be greatly appreciated. Regardless
of whether QWebService will make it into Qt5 or not, the package is
currently fully usable and can be used as a separate product. Enjoy,
if you wish to :) Here's a small teaser of the QtDevNet example:
http://youtu.be/00tZ04XPj98
Cheers,
sierdzio
l***@nokia.com
2011-09-23 20:15:44 UTC
Permalink
Post by Tomasz Siekierda
Hi,
again, long time no see, but I'm coming back with more or less good
news, and some questions.
I've filled merge request (#51) for QWebService (converter is
temporarily waiting), and got some feedback from Thiago. He did
propose to move my sources from QtNetwork into an add-on. I find this
idea very good, but wish to enquiry here. What is your view on that?
(if anyone happens to have any, that is).
Same view as Thiago from my side. Having it as an addon is IMO the best
solution here. It gives you some more freedom in terms of developing and
maintaining the code and I personally also don't want to add this directly
to QtNetwork.

Cheers,
Lars
Post by Tomasz Siekierda
In other news, sources got updated to v0.5.0, with many improvements -
most behind the scenes, but there are also some API updates. Repos can
- (main repo, separate from Qt) https://gitorious.org/qwebservice
- (merge request) https://qt.gitorious.org/qt/qtbase/merge_requests/51
https://gitorious.org/~sierdzio/qt/sierdzio-qtbase-qwebservice
https://gitorious.org/~sierdzio/qt/sierdzio-qttools-qwebservice
Just as usual, any feedback would be greatly appreciated. Regardless
of whether QWebService will make it into Qt5 or not, the package is
currently fully usable and can be used as a separate product. Enjoy,
http://youtu.be/00tZ04XPj98
Cheers,
sierdzio
_______________________________________________
Qt5-feedback mailing list
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback
Tomasz Siekierda
2011-09-30 09:18:05 UTC
Permalink
Sorry for the delay, I was busy the whole week. OK, so I'll move my
code into and add-on. I've looked through a ton of documents, mostly
QtDN wikis and Qt documentation, a few new questions have emerged.

1) I cannot find a definite answer on what is actually considered to
be an add-on. For example, the newly separated widgets is said to be
an add-on, and resides in qt5/qtbase/src/widgets. QtXmlPatterns is
also considered an add-on, but occupies a full separate repo at
qt5/qtxmlpatterns. Where should I put my code, then? Into Qt5 main
repository, or into qtbase? I would kind of opt for the former, as it
would help me keep sources, examples and tests in one place (for
example qt5/qwebservice).

2) What about tests and examples? Tests for various add-ons that
reside inside qtbase seem to be placed there in a more or less random
fashion, with some having their own subfolders, while others happily
share directory structure with the rest of the suite (that is, with
tests of Qt Essentials).

3) Can I include the WSDL converter application in my add-on, or does
it have to stay separate?

4) Should I delete my current merge request now?

Cheers,
sierdzio
Post by l***@nokia.com
Post by Tomasz Siekierda
I've filled merge request (#51) for QWebService (converter is
temporarily waiting), and got some feedback from Thiago. He did
propose to move my sources from QtNetwork into an add-on. I find this
idea very good, but wish to enquiry here. What is your view on that?
(if anyone happens to have any, that is).
Same view as Thiago from my side. Having it as an addon is IMO the best
solution here. It gives you some more freedom in terms of developing and
maintaining the code and I personally also don't want to add this directly
to QtNetwork.
Cheers,
Lars
Thiago Macieira
2011-09-30 09:41:13 UTC
Permalink
Post by Tomasz Siekierda
1) I cannot find a definite answer on what is actually considered to
be an add-on. For example, the newly separated widgets is said to be
an add-on, and resides in qt5/qtbase/src/widgets. QtXmlPatterns is
also considered an add-on, but occupies a full separate repo at
qt5/qtxmlpatterns. Where should I put my code, then? Into Qt5 main
repository, or into qtbase? I would kind of opt for the former, as it
would help me keep sources, examples and tests in one place (for
example qt5/qwebservice).
Hi Tomasz

The definition is somewhat in flux. I think Henry produced some documents and
placed them on the QtDN.

We divide Qt into the Qt essentials and the addons. The essentials are those
libraries and repositories that all installations of Qt offering Qt as an API
must have: that's Qt Base, Qt Quick and QtWebKit. Everything else is an addon,
some of which will become quite standard and widespread.

As for the qt5 repository, it was created as a way for ease transition from
Qt 4. But I'm personally not sure how we should treat it going forward. For
example, the "qtphonon" sub-module makes no sense to continue, as Phonon
building should be done using CMake, not qmake.
Post by Tomasz Siekierda
2) What about tests and examples? Tests for various add-ons that
reside inside qtbase seem to be placed there in a more or less random
fashion, with some having their own subfolders, while others happily
share directory structure with the rest of the suite (that is, with
tests of Qt Essentials).
They should stay as close as possible to the code itself. The randomness you
see is a result of moving legacy code around.
Post by Tomasz Siekierda
3) Can I include the WSDL converter application in my add-on, or does
it have to stay separate?
Keep it together if you think it's useful.
Post by Tomasz Siekierda
4) Should I delete my current merge request now?
You can leave it there, but it won't get merged to QtNetwork.
--
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
Software Architect - Intel Open Source Technology Center
PGP/GPG: 0x6EF45358; fingerprint:
E067 918B B660 DBD1 105C 966C 33F5 F005 6EF4 5358
Continue reading on narkive:
Loading...