Page 1 of 1

Remote method call for wxWidgets?

Posted: Thu Jul 05, 2007 8:51 am
by krzysiek_t
Hi,
Do you think it would be handy to have portable remote method call future in wxWidgets?

Personally, I hate coding network communication with sockets. It's low-level and error prone.

Pozdr.
Krzysiek

Posted: Fri Jul 06, 2007 6:13 am
by priyank_bolia
You can use web services using soap. I tried gSOAP with wxWidgets, it was good.

Posted: Fri Jul 06, 2007 12:26 pm
by krzysiek_t
Looks very interesting, especially as it gives remote method call abstraction and code portability. I have to try it. Thanks. Maybe I'll abandon the idea of own solution ;-)
priyank_bolia wrote:You can use web services using soap. I tried gSOAP with wxWidgets, it was good.

Posted: Fri Jul 06, 2007 4:37 pm
by priyank_bolia
krzysiek_t wrote:Looks very interesting, especially as it gives remote method call abstraction and code portability. I have to try it. Thanks. Maybe I'll abandon the idea of own solution ;-)
priyank_bolia wrote:You can use web services using soap. I tried gSOAP with wxWidgets, it was good.

Writing own network libraries has other problems too, other than abstraction and code portability. You have to deal with various networking issues, firewall, NAT, etc... and code writing is also a pain. And my opinion about wxWidgets network libraries is also not good.
The benefit from web services is that, like you have a client team and a server team, then they need not to know each other. They can work in isolation without any communication bottleneck and can upgrade each other components independently. All you need is just a WSDL contract. Also gSOAP is free, you can try it and when you want to release your application just pay one time fee of may be less than 100$. It can generate the complete client and server code in less than the time you will just write a simplest networking program.
Also see http://www.wsdlgenerator.com/ and google offcourse :D

Posted: Fri Jul 20, 2007 8:32 am
by krzysiek_t
Well - gSOAP for C++ with JAX-WS for Java and I shall have quite a nice interoperability between my C++ program and my Java app.

But... SOAP is heavy, very heavy - as each XML is.

Still my dream is something CORBA-like, but with few modyfications. It shoul have portable C++ implementation (like gSOAP) and it should have Java support (like SOAP) ;-)

Posted: Sat Jul 21, 2007 11:23 am
by clyde729
I suggest to communicate via XML-RPC. I worked on a project, where a Java-server and C++ - clients worked together. For lowlevel communication we used TCP-sockets and for data-exchange we used a (own written) modified version of XML-RPC. It's much more easier than SOAP or CORBA and it is still human-readable.

Posted: Thu Aug 16, 2007 10:25 am
by krzysiek_t
Well - yesterday was the day when I've achieved C++/gSOAP and Java/JAXWS interoperabilty. I've written simple servers (C++ and Java versions) and simple clients (C++ and Java versions). Each client could talk with each server! Clients were calling simple remote function with no parameters which returning only a string value - some kind of "hello world" app.

Unfortunately gSOAP has problems with C++ standard collections like std::list... :-|

Posted: Wed Feb 20, 2008 1:44 pm
by krzysiek_t
gSOAP is quite OK. I've solved the problem with std::list :-D

Posted: Thu Feb 21, 2008 6:37 am
by clyde729
Good job, man! =D> If you would have some simple application(s) to share then I (and I'm shure others, too) would be very interested in your expertise. Nice to hear that it really works!

Posted: Thu Feb 21, 2008 6:12 pm
by Sof_T
gSOAP is quite OK. I've solved the problem with std::list
Always nice to solve a problem :D

I am at present also writing a server client project. For added interest it needs to be able to take input from web browsers as well.

To acheive communication between clients written in different languages I am implementing REST and responding to HTTP messages with data formatted with JSON, thanks to the wxJSON library. It works very nicely and is ever so simple to implement.

Sof.T

Posted: Fri Feb 22, 2008 3:09 am
by priyank_bolia
clyde729 wrote:If you would have some simple application(s) to share then I (and I'm shure others, too) would be very interested in your expertise.
Just create a wsdl and run the gsoap tool, and it would generate the whole client server code. The only thing that is needed is calling the function from your application.