We carried out a simple performance comparison between WSF/C++ , WSF/C against a set of other web services products. The results are published here.
Wednesday, March 10, 2010
http://wso2.org/projects/wsf/cppWith the availability of WSO2 WSF Admin, now users can manage their C and C++ Web Services Deployed in Axis2/C, WSF/C or WSF/C++ using the GUI interface of Carbon. At present, WSF Admin is at first milestone and supports following set of features.
Service Listing and Module Listing
Following are some of the screen shots of New WSF Admin Console with WSF/C++.
Engage Statistics Module to a service using the admin console and view the service usage statistics.
View and Edit Service Policies
There are lots of other functionality in-addition to the once I have shown above. WSF Admin is a set set of web services and modules implemented using WSO2 Web Services Framework, plus a Customized Carbon Instance. The Admin Console works by using web services interactions to the WSF/C Back End where the C Admin Services deployed. WSF Admin is also a demonstration of not only the interoperability of WSO2 products ( Between java based Carbon Platform and C/C++ based WSF Products ) but also the flexibility of WSO2 Carbon Platform.
WSF Admin milestone 1 release does not have the persistence and hence the configuration changes you make will not be preserved once you shutdown your server. The next release of WSF Admin will be having the persistence capability.
Monday, January 18, 2010
When you have to go beyond the supported interface of a ServiceSkeleton when implementing a service, you can use a custom message receiver to achieve that functionality. For example, recently we encountered such scenario where the unparsed soap enveloped body has to be accessed for some custom logic. But when implementing a service using ServiceSkeleton interface, you would always ended up getting the first child of the soap body as an argument.
In that kind of a situation, the best option would be to implement a custom message receiver. WSF/CPP now provides a very convenient API for implementing a message receiver.
For implementing a custom message receiver, WSF/CPP provides a class named MessageReceiver. What a user has to do is to extend from this and implement the abstract method invokeBusinessLogicSync which will receive inflow message context and outflow message context as arguments. Then you have the full control over the processing of the message received by the message receiver.
Next add the macro WSF_MESSAGE_RECEIVER_INIT and pass the message receiver class name as the argument.
Next compile the written code as a shared library and place it in <WSFCPP_REPO>\lib directory. When implementing a service which would be invoked using this custom message receiver, set the name of the shared library as the “messageReceiver” parameter for each operation. For example, if the shared library name is “CustomMsgRecv”
<operation name=”Op1”><messageReceiver class=”CustomMsgRecv”/></operation>
Here is the example message receiver code.
/* CustomMsgRecv.h */
class CustomMsgRecv : public wso2wsf::MessageReceiver
WSF_EXTERN bool WSF_CALL
/** CustomMsgRecv.cpp */
using namespace wso2wsf;
WSF_EXTERN bool WSF_CALL
/** Add Your Logic Here */
Thursday, November 5, 2009
I will be doing a webinar on WSF/C++ on 10th November. If you are looking to incorporate native web services stack in your web services solution, this webinar will be of great value for you to evaluate WSF/C++ and get to know the capabilities and get started and what's more its free. This webinar will be a technical oriented one with covering lots of details on how you can use WSF/C++ framework.
Registration for webinar is now open. Looking forward to seeing lots of you turn-up for the webinar. :)
Friday, October 30, 2009
WSF/C++ comes with the build in code generation tool which allows you to generate Client Stubs and Service Skeletons in C++ by pointing to a WSDL.
If you downloaded the windows binary zip file, you will get the code generation tool binary jar files. If you download the source distribution, you will have to build the tool before using it.
1. Building from the source. On Linux.
In the outermost directory of the source distribution, the build script for building the codegen tool is available. It is named build_codegen.sh.
First you need to build and install wsf/cpp to a preferred location. .you would need to download and install maven2. Then specify the directory where you have build and installed the wsf/cpp.
I have installed the wsfcpp to the location /home/nandika/wsfcpp. directory.
$ sh build_codegen.sh /home/nandika/wsfcpp.
This would build and copy the jar files and codegen scripts to the directory /home/nandika/wsfcpp/bin/codegen/ directory.
2. Building from the source, on Windows
On windows, again, you need to have installed mavan2. First edit the configure.in file and run the build.bat file located in the outermost directory of the source distribution in order to build and make the binary dist.
Next run the build_codegen.bat file to build the code generation tool jar files from the source. Next run the copy_codegen.bat file to copy the code generation tool and its scripts to the bin directory of the binary distribution. It will be located in the directory bin\tools\codegen directory.
3. Codegen tool Options
Code Generation tools provides you will multiple options.
Some of the most common options are
1. –uri –> Specify the uri to the wsdl
2. –d -> Data binding option ( This can be either adb or none )
3. –u -> Unpack classes option
4. –0 -> Specify the output directory
5. –uw –> Unwrapped mode ( allows you to generate simple parameters for operations instead of data binding classes )
6 –ss -> Generate Service Code
7. –sd -> Generate Service deployment descriptors and build files ( services.xml and build.sh )
An example code generation command.
wsdl2cpp.sh –uri calculator.wsdl –d adb –u –uw –o calculator
This command instruct the codegen script to use the calculator.wsdl file located in the same directory and generate client side code ( default ) with adb data binding and use the unwrapped mode. It will output the generated source code to the calculator directory.
Sunday, October 18, 2009
We are pleased to announce the release of WSO2 Web Services Framework for C++ 2.1.0 release. With this 2.1 release comes some very useful usability enhancements in addition to many improvements to the framework.
Now the code generator tool is able to generate visual studio project files for the generated code. In addition, we have released an eclipse plug-in wizard alone with this release, which provides a comprehensive GUI interface to the code generator tool. This will allow the users who are working within eclipse IDE to generate code without having to leave the IDE.
We have done some work to improve the performance of the WSF/C framework within this period of time. In addition, the many shortcomings in the code generation tool has been addressed from the previous release.New samples were added. Also some platform specific issues have been addressed in this release which allowed WSF/C++ to be complied in both MacOS as well as Solaris without having to do any changes.
Here is the complete release note.
WSO2 Web Services Framework for C++ (WSO2 WSF/C++) 2.1.0 Released
WSO2 WSF/C++ team is pleased to announce the release of WSO2 WSF/C++ 2.1.0.
You can download this release from: http://wso2.org/downloads/wsf/cpp
WSO2 Web Services Framework for C++ (WSO2 WSF/C++) is a standards compliant, enterprise
grade, open source, C++ library for providing and consuming Web services in C++, based on the popular,
WSO2 WSF/C library.
Project home page:
1. Client API to consume Web services
* ServiceClient class with one-way and two-way service invocation support
for SOAP 1.1, and SOAP 1.2.
* Options class to facilitate configuring the client for both SOAP and REST options.
2. Service API to provide Web Services
* ServiceSkeleton class to extend from to implement services.
2. Attachments with MTOM
* Binary optimized
* Non-optimized (Base64 binary)
* Attachment Caching Support
* Version 1.0
* Username Token
* Timestamp Token
* WS-SecurityPolicy based configuration
* Reply detection
* WS-Secure Conversation
6. Code generation Tool
* By providing a wsdl and options, generate client stubs and service skeletons
in C++ using the code generation tool.
* A Code generation Eclipse plugin is also available with this release. The code generation tool
has been integrated into an eclipse plugin wizard which allows a user to conveniently
utilise the code generation tool while working within eclipse.
7. SSL enabled transport layer
8. WS-Reliable Messaging
9. Has all the capabilities available from WSF/C library.
Major Changes Since Last Release
1. Eclipse plugin for code generation tool added.
2. Visual Studio project file generation is added to the code generation tool.
3. Documentation Improved.
4. Many bugs fixed in the code generation tool.
5. Many memory leak fixes.
6. More samples have been added.
7. The Service API has been enhanced to allow users to extend from the generated skeleton classes.
There could be memory leaks in some scenarios.
Issues can be reported using the public JIRA available at:
Please subscribe to our user or developer mailing lists. For details on how
to subscribe please visit: http://wso2.org/mail
Questions could be raised using the WSF/C++ forum.
WSO2 Inc. offers a variety of professional Training Programs which includes training on WSF/C++.
For additional information please refer to http://wso2.com/training/
WSO2 Inc. offers a variety of development and production support programs, ranging from Web-based
support up through normal business hours, to premium 24x7 phone support.
For additional support information please refer to http://wso2.com/services/support/
We welcome your early feedback on this implementation.
Thank you for your interest in WSO2 WSF/C++.
-- WSO2 WSF/C++ Team --