Hi Minakari,

It all depends how you want to run your application. If you have a web
application you want to deploy into a servlet container, you will create
a servlet which launches the OSGi framework into which you install your
bundles.

Turned the other way run, you may launch an OSGi framework and deploy a
servlet container as one of the bundles. The servlet container bundle
would typically implement the OSGi HTTP Service Specification. See the
Apache Felix http.jetty bundle for such an example.

To use tomcat, you may use it as a servlet container as described in the
first use case or you may wrap it in an OSGi bundle as described in the
second case. Of course in the second case, you may also use the existing
and - to some extend - proven bundling provided by the http.jetty bundle
instead of build your own bundling around tomcat. But then your mileage
may vary :-)

Real-life examples of both uses cases are implemented in the Apache
Sling [1] project: The launcher/app subproject implements the second use
case (servlet container as a bundle in the OSGi framework) while the
launcher/webapp implements the first use case (OSGi framework in a web
app to be deplyoed into a servlet container).

Hope this helps ...

Regards
Felix

[1] http://incubator.apache.org/sling/

Am Sonntag, den 06.01.2008, 23:42 -0800 schrieb minakari:
> Is ther any sample for use OSGI in web Application and with tomcat web
> server?what about tomcat??how I can use tomcat in this new way ?whether I
> should use tomcat as a bundle?so how can I do that?
> I am realy confused.
> 
> best regard. 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to