Saturday, July 5, 2008

Light weight, OSGi based, Axis2 powered, web services application server in 5 minuets

Few days back I blogged about "Embed Eclipse Equinox in a Servlet Container". Let's extend this idea a little bit more to write your own light weight, OSGi based, Axis2 powered, web services application server.

There is an ongoing effort to extend Axis2 Web Services engine to deploy as a bundle in an OSGi environment. The purpose of this extension is to allow deployed bundles to provide services and modules which will be recognized by OSGi based Axis2 engine and deploy them.

Let's create the light weight, OSGi based, Axis2 powered, web services application server using Eclipse Equinox OSGi implementation and Apache Tomcat.

1. Download Apache Tomcat
2. Download bridge.war from Eclipse Equinox.
3. Download commons logging (org.eclipse.equinox.common_3.3.0.v20070426.jar) bundle from Eclipse Equinox.
4. Copy the downloaded bridge.war to Apache Tomcat webapps directory
5. svn co osgi_test
6. Go to osgi_test directory and type "mvn clean install -U". You need Maven2 build system.
7. Go to osgi_test/distribution/target directory and unzipped
8. Copy all the bundles from distribution-1.0.0/plugin folder to /webapps/bridge/WEB-INF/eclipse/plugins and copy commons logging bundle too.
9. Restart Tomcat
10. On the osgi> command prompt start all bundles except fragment host bundles.

11. http://localhost:8080/bridge/services/Version?wsdl

You have your personal light weight, OSGi based, Axis2 powered web services application server.


Loïc said...

I've some problem to finish the maven process because some artifacts are not found (I'm using this maven repository located here:

3) org.apache.axis2:org.apache.axis2.osgi:jar:SNAPSHOT

For the first and the second one, I've injected into my local maven repository these "fake" jar:

But for the third artifact, I'm not able today to found a valid jar file.

Do you know where I can found an axis2-osgi.jar binary file? Do you know when the axis2-osgi will be released?

Thanks a lot for your article


Saminda Abeyruwan said...


Since Axis2 OSGi integration is currently in Axis2 trunk, you will be able to get the latest as SNAPSHOT. This is true for Axiom as well.

thus using mvn clean install -U will allow you to download the latest

Faisal said...
This comment has been removed by the author.
Mohannad said...

Hi there,
I was searching for some material regarding axis2 and rampart and i came across your blog, im wondering if you can help me. Ive got an axis2.osgi snapshot (from your blog and i need to use the rampart module with it for signing and encrypting messages. Do you know how i can get rampart to work with that snapshot?

Any help would be appreciated

Mohannad Hammadeh

indiroma said...

ITSolusenz departments manage all components of software development including, Application Development Company, software development company india, Software Development Services.

Johannes said...


I cannot get this run. I managed to build all the bundles (providing axiom 1.2.8 for axiom-dom and -impl). But when I try to start the axis2-osgi-bundle I get an error (event it seems that all dependecies are fullfilled). Here is my bundle-list and the log of starting axis2. Any ideas what went wrong? Maybe I'm using the wrong axiom-version but I tried trunk and 1.2.8 with similar results:

any help would be highly appreciated,

best regards

Rajesh Girish said...

Hi Where do we get proper support for OSGI Axis2 Right now i don't see
any replies for the below comments.Even i'm facing similar problems....

If any there is any forum for this
please do inform us or reply to the comments..

Rajesh Girish said...

I get the Following error when "mvn clean install -U"

Internal error in the plugin manager getting plugin 'org.apache.axis2:axi
s2-mar-maven-plugin': Plugin 'org.apache.axis2:axis2-mar-maven-plugin:20090713.0
61207-124' has an invalid descriptor:
1) Plugin's descriptor contains the wrong version: SNAPSHOT

Ashok K.R said...

very nice article, Weight Loss Pills

steven said...

I am always connect with friends through blogger.nice post Thanks for Sharing
More templates easy to download

మహా నాగార్జున said...

Is there any way to build all the Axis2 libs to OSGi bundles?

thiroux34 said...

First of all thanks for this article.
I checked out all from I compiled all using mvn clean install -U.
When I tried to launch the org.apache.axis2.osgi_1.0.0.SNAPSHOT bundle, I got the following message: The bundle could not be resolved. Reason: Missing Constraint: Import-Package: javax.jms; version="1.1.0". I tried - without success - to find a bundle which export this package.
Any help will be highly appreciated.

gemini said...

Gemini Info Way (GIW) Provide the Following Services,Web design, Flash Website Design, Banner Design, Flash Design , Flash Banner Design, web hosting, SEO, web development, online dating, e-commerce, graphic design, Vector based drawing, Brochure design, Banner Design, Flash Animation, Flash presentation, Flash Website, 3d Animation, 3d Landscape, 3dObject modeling, 3d Character modeling, 3d Story Animation, 2d Story board, 2d Story Animation, Gif Animation -

Steve said...

Hi Saminda,

I'm using your axis2.osgi.jar to build some web services on top of Felix. I'm able to get a web services deployed and it is reachable from my browser. More particularly, the


are reachable from the browser. However, when I try to write my own web service client, I notice that the endpoints don't exist. I get the following exception when I send something to this EPR "Operation not found is http://localhost:8080/services/someService
and the WSA Action = someAction". This is because the EPR that I specify are "localhost:8080/services/[service_name]". When I type that directly into my browser, I get the same error message and the EPR doesn't exist while the wsdl and web services operations are functional. I tried the same thing on the standard Axis2 download and the endpoint is there. In fact, if I go to localhost:8080/axis2/services, I'm able to see all the services available on the standard version.

So with the current axis2.osgi.jar, is it possible to target the endpoints directly and not their ?wsdl or operations? If so, how can I do this?

Thank you for your article.

collin said...

Very nice post. I am here for the first time and i loved your post. Keep posting further about server technologies.

Collin paul

Vinay said...


I'll be thankful, if you can please share some information about how to invoke a web service hosted on Apache tomcat running on a remote machine through an OSGi bundle.

Thank you.

Strong Watchman said...


How does this Axis2 web services application server compare to WAMP. I am trying to understand the difference. WAMP is the Apache based web server which I have running on my Windows 2003 server.

Can you just point me in the right direction of what a web services application server is used for?

Thanks...good detail on this post.

Isagenix Watchman

Pank's Bloggg said...

Hi Saminda Will you please provide me some details that how can I deploy your(Axis2 with osgi) application into jboss eap6.

Patrick Martin said...

Hi Saminda,

I'm trying to view your documentation to set up Axis2 web services in the Equinox ServletBridge, (osgi_integration.pdf), but I get the following error:

svn: E170000: URL '' doesn't exist

Have you moved your documentation elsewhere?

Thanks very much!

Mitesh Pandit said...

Hi Saminda,

Thanks for detailed guide. However, I am stuck with the last part and not able to build simple.module bundle.
I get compilation error package org.apache.neethi does not exist even though I have neethi-2.0.4, neethi-2.0.4-SNAPSHOT,neethi-3.0.1 and neethi-3.0.3-SNAPSHOT present in my maven repository. Can you please share simple.module.jar or guide how can I resolve this problem?

[INFO] ------------------------------------------------------------------------
[INFO] Building simple.module bundle
[INFO] task-segment: [clean, install]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean {execution: default-clean}]
[INFO] Deleting directory C:\Users\mpandit\saminda\osgi_test\simple.module\targe
[INFO] [resources:resources {execution: default-resources}]
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources,
i.e. build is platform dependent!
[INFO] Copying 1 resource
[INFO] [compiler:compile {execution: default-compile}]
[INFO] Compiling 3 source files to C:\Users\mpandit\saminda\osgi_test\simple.mod
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure

osgi\module\[23,24] package org.apache.neethi does not exist

osgi\module\[24,24] package org.apache.neethi does not exist

osgi\module\[40,39] cannot find symbol
symbol : class Assertion
location: class org.apache.axis2.osgi.module.SimpleModule

osgi\module\[44,28] cannot find symbol
symbol : class Policy
location: class org.apache.axis2.osgi.module.SimpleModule

[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 12 seconds
[INFO] Finished at: Wed Jan 30 05:03:47 PST 2013
[INFO] Final Memory: 22M/53M
[INFO] ------------------------------------------------------------------------

Wilson Peter said...

Hi Saminda,
I loved reading this piece! Well written! :)

Wilson Peter
Dating Service Miami Florida

Devid Jonson said...

Awesome ! this is very informative post for me.Thanks to the admin! You have written glorious!

Devid Jonson
web design sydney
web designbrisbane
web design brisbane

John Dudley said...

IT companies are gaining popularity with every passing day and tend to grow at a rapid speed. Software development company procedures are getting purifies and verified with a brilliant merge of existing and new technologies everyday. Due to the massive demand of automation and perfection, many organizations are now opting outsourcing software development in order to meet their business needs.

zareena gull said...

Hello! I am simply a novice regarding the matter of blogging. Really, I have quite recently begun. I might want to know whether I can present a few promotions on my wordpress blog regardless of the possibility that the webpage is free. That is to say, I don't claim an area yet since I can't manage the cost of it for the interim. It would be ideal if you help me. If its not too much trouble let me know how to post promotions on my free wordpress blog. Much obliged much! Also btw, pleasant illumination you got there. I am gaining from your site…
web development company uae

Jasos Angla said...

There is lot of articles on the web about this on topic of automation services.
But I like to give you more,although i found one that’s more dateils.It's rather a nice useful little bit of information.

automation services

mdakboralibdn said...

Hello guys,
I found this blog to be usefull for this king of category.
I have something to say that can help many of you.
Some of the steps included in web designing would be having a domain name,
hosting the domain, web development, and designing.for more info
web design brisbane

Web Design City said...

website design sydney

Raihan said...

Hello guys,
I found this blog to be usefull for this king of category.
I have something to say that can help many of you.
Some of the steps included in web designing would be having a domain name,
hosting the domain, web development, and designing.for more info
web design brisbane

jerry franklin said...

The Olympics Opening Ceremony kicks off in PyeongChang on February 9, 2018. Here's everything you need to know about the 2018 Winter Games.
live hours of Winter Olympics opening ceremony coverage in PyeongChang
Winter Olympics Opening ceremony date and time
Winter Olympic Games live online free
Alpine skiing live 2018

Roshan Ali said...

Excited for upcoming boxing fight between Joshua vs Wilder do check this links.

Anthony Joshua
Boxing live stream
What time does the fight start
Who won fight last night

John N Brown said...
This comment has been removed by the author.
Bruce Williams said...

This time around, this famous grand slam, which is played on clay, will start on the 27th of May 2018 and will end on 10nth of June 2018. Truth be told, there are plenty of ways to watch french open 2018 live stream. Many of the ways require the user to pay a certain amount of money to access a live stream or something similar.There are also some free channels that stream Roland Garros live.

Bruce Williams said...

The 102nd Indianapolis 500 is set for Sunday, May 27, but first the lineup and starting grid, including the pole sitter, have to be determined. This is done on Pole Day, where the top nine drivers battle it out for the top position to lead off the race.indy 500 live stream 2018

Charles Crowe said...

I am impressed by the information that you have on this blog. It shows how well you understand this subject.
FIFA World Cup live
World Cup 2018 live
World Cup live

Nill Akhash said...

I am impressed by the information that you have on this blog. It shows how well you understand this subject.
Queensland vs New South Wales live
QLD vs NSW live
State of Origin game live

Charles Crowe said...

You might comment on the order system of the blog. You should chat it's splendid. Your blog audit would swell up your visitors. I was very pleased to find this site.I wanted to thank you for this great read!!

french open live
roland garros live
roland garros stream
french open live free