Kevin,
The config file makes Jetty look way more configurable than Jo!. Jo's
only interface is the publish of deploy (and undeploy) as shown. As
such Jo cannot refer to things outsde the WAR file. This is good and
bad. Good in that a SAR file distro of something containing Jo is
likely to work wherever it arrives. Bad in the same way that WAR files
have hindered the adpotion of JSP in commercial web hosting - people
like to replace individual files in a running server (PHP, Perl etc).
The config file is from you own application, yes? in includes absolute
file references like /home/ksmith/ . I think to be more useful to a
wider Phoenix using audience ...
<doc-root>/home/ksmith/projects/jakarta-avalon-phoenix/dist/apps/ptolemy-server</doc-root>
... might be more flexible as ...
<doc-root type="absolute"
path="/home/ksmith/projects/jakarta-avalon-phoenix/dist/apps/ptolemy-server"/>
<doc-root type="relativeToSarRoot" path="."/>
What do you think?
On the issue of standardizing an API. Desirable? - yes. Possible?
Maybe. I think in the end we would need get the involvement of both
Hendrik Schreiber and the people at Mort Bay. The interface as you know
does not have to tied to Phoenix. Other embeddors could use it too :
StandandWebServerInterface ws = new Jetty();
StandandWebServerInterface ws = new Jo();
For now though, I think you should evolve your service interface as far
as you can to be useful to others. We can shove the code in
jakrta-avalon-apps/jetty (if you want) and standardize later as
developers start using it. Make sure we mark it as subject to change,
and later when the Jetty folks get interested, we have a mandate to
standardize.
Thoughts?
Regards,
- Paul
>Paul -
>
>I'd definitely be interested in helping standardize the interface for
>servlet containers. Jetty has something like that but I haven't
>implemented a wrapper function in the Block for it, because I'm not using
>WAR files. But it could be easily done.
>
>Just taking a quick look at the config for this block, the following
>params are configurable:
>
>bind-host
>bind-port
>doc-root
>
>Then for each servlet, you can specify:
>
>deployName
>servlet-class
>url-pattern
>0 to n init-params (just name-value pairs passed to the servlet during
>initialization)
>
>I've attached a copy of my config.xml to give an idea of how I've wrapped
>Jetty. Does this resemble at all how the Jo! block works?
>
>--Kevin
>On Thursday 14 March 2002 11:12 am, you wrote:
>
>>Kevin,
>>
>>>This is where I think I'm confused. Is a <provide> tag the equivalent
>>>of a <dependency> tag?
>>>
>>What Stephen said.
>>
>>>As for the ServletContainerService, I'm writing a Block for the Jetty
>>>servlet engine. I'm about 80% there: you can deploy servlets and use
>>>JSPs. I need to polish some rough edges (NullPointerExceptions instead
>>>of 404 messages, etc) and add meaningful logging.
>>>
>>Very Kool. That would make two HTTP/Sevlet containers. Maybe it is
>>time to think of a standard service interface for HTTP, and WAR file
>>capable ones.
>>
>> Jo! has ..... void deployWAR(String hostName, String name, String
>>ctxPath, String warUrl)
>>
>>- Paul
>>
>>
>>------------------------------------------------------------------------
>>
>><?xml version="1.0"?>
>>
>><config>
>>
>> <ServletEngine>
>> <bind-host>localhost</bind-host>
>> <bind-port>6513</bind-port>
>>
><doc-root>/home/ksmith/projects/jakarta-avalon-phoenix/dist/apps/ptolemy-server</doc-root>
>
>> <servlet deployName="JSP">
>> <path>/</path>
>> <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
>> <url-pattern>*.jsp:*.htm:*.html</url-pattern>
>> <init-params>
>>
><classpath>/home/ksmith/projects/ptolemy-server/lib/javax.servlet.jar:/home/ksmith/projects/ptolemy-server/lib/org.apache.jasper.jar:/home/ksmith/projects/ptolemy-server/lib/tools.jar:/home/ksmith/projects/ptolemy-server/lib/rt.jar:/home/ksmith/projects/jakarta-avalon-phoenix/dist/apps/ptolemy-server</classpath>
>>
><classpath>/home/ksmith/projects/ptolemy-server/lib/javax.servlet.jar:/home/ksmith/projects/ptolemy-server/lib/org.apache.jasper.jar:/home/ksmith/projects/ptolemy-server/lib/tools.jar:/home/ksmith/projects/ptolemy-server/lib/rt.jar</classpath>
>> <scratchdir>/tmp</scratchdir>
>> <sendErrToClient>true</sendErrToClient>
>> <mappedfile>true</mappedfile>
>> </init-params>
>> </servlet>
>> <servlet deployName="Core">
>> <path>/servlet/core</path>
>>
><servlet-class>com.electricanvil.ptolemy.server.app.web.servlet.MainListener</servlet-class>
>> </servlet>
>> </ServletEngine>
>>
>></config>
>>
>>
>>------------------------------------------------------------------------
>>
>>--
>>To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
>>For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
>>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>