users@grizzly.java.net

Re: Sample and document about grizzly-http-servlet

From: Marc Arens <marc.arens_at_open-xchange.com>
Date: Mon, 16 Jun 2014 10:40:57 +0200 (CEST)

Moin,

Grizzly let's you deploy Servlets and Filters via a Servlet/WebappContext that
deploys to a HttpServer instance. See [1] for some examples. Furthermore you can
deploy Servlets via the OSGI HttpService implemented by Grizzly. I'm not sure
about deployment via web.xml and friends, there have been some approaches to
serve content from jars but you'll have to search the mailinglist for this.

[1]
https://github.com/GrizzlyNIO/grizzly-mirror/blob/2.3.x/modules/http-servlet/src/test/java/org/glassfish/grizzly/servlet/BasicServletTest.java

> On 16 June 2014 at 10:14 Johan Maasing <johan_at_zoom.nu> wrote:
>
>
> There is no straight answer to that question since that is actually two
> things at once you are asking :-) There is an HTTP-framework in grizzly but
> it has nothing to do with the servlet specification.
>
> The servlet specification is implemented in the glassfish project/server (
> http://glassfish.java.net).
>
> So, if you really need _servlets_ (as in the JEE-specification, with
> web.xml, JSPs and all that stuff) I would suggest glassfish, tomcat, jetty
> or similar.
>
> But if you just want to write java code to create HTTP-responses and don't
> care about the servlet specification you can implement HttpHandlers as in
> the samples here: https://grizzly.java.net/httpserverframework.html
>
> I hope I got all this right, I'm pretty new to grizzly :-)
>
> Cheers,
>
> JM
>
>
> Den 16 jun 2014 08:54 skrev "LongkerDandy" <longkerdandy_at_gmail.com>:
>
> > Hi
> >
> > Is there any document/sample about Grizzlt's servlet implementation.
> > Like hotwo start with a web.xml and configured handler.
> >
> > Regards
> > LongkerDandy
> >

Best regards,
Marc