Hello,

Thanks for this new doc! Looking at your code, it seems that you could
simplify it a lot using this approach:

Instead of doing:

        //create embedding jetty server
        Server embedingJettyServer=new Server(
                component.getContext(),
                Protocol.HTTP,
                8182,
                component
            );
        //construct and start JettyServerHelper
        JettyServerHelper jettyServerHelper=new
HttpServerHelper(embedingJettyServer);
        jettyServerHelper.start();

You can just do:

        //create embedding jetty server
        Server embedingJettyServer=new Server(
                component.getContext(),
                Protocol.HTTP,
                8182,
                component
            );
        embedingJettyServer.start();

Also, for AJP, there is a Protocol constant you should use:

        //create embedding AJP Server
        Server embedingJettyAJPServer=new Server(
                component.getContext(),
                Protocol.AJP,
                8183,
                component
            );
          embedingJettyAJPServer.start();

There is no need to manually reference the helper classes. You just need to
use classes in the Restlet API, without dependency on NRE classes. Also,
your source code excerpt doesn't attach the application to the component. It
might be better to attach the full source code instead of pasting it
directly in the documentation. Only the code part specific to AJP
configuration could be retained.

Beside that, your document is very useful. It only misses an introduction
paragraph explaining what you are about to cover, what is the interest of
AJP (short) in this case. 

Keep up the good work!

Best regards,
Jerome 

> -----Message d'origine-----
> De : cleverpig [mailto:[EMAIL PROTECTED]
> Envoyé : vendredi 15 février 2008 03:10
> À : [email protected]
> Objet : new document:“Embedding Jetty & AJP”
> draft,pls review
>
> Embedding Jetty &
> AJP:http://wiki.restlet.org/docs_1.1/g1/43-restlet/55-restlet.html
>
> --
> cleverpig



Reply via email to