jsr369-experts@servlet-spec.java.net

[jsr369-experts] Re: [servlet-spec users] Re: Re: SERVLET_SPEC-137: Allow context root

From: Mark Thomas <markt_at_apache.org>
Date: Wed, 2 Sep 2015 08:31:47 +0100

On 01/09/2015 23:29, Stuart Douglas wrote:
>
>
> ----- Original Message -----
>> From: "Edward Burns" <edward.burns_at_oracle.com>
>> To: jsr369-experts_at_servlet-spec.java.net
>> Sent: Wednesday, 2 September, 2015 6:40:24 AM
>> Subject: [jsr369-experts] Re: SERVLET_SPEC-137: Allow context root
>>
>> MT> On 01/09/2015 01:15, Shing Wai Chan wrote:
>>
>> SWC> If this is a Servlet 4.0 feature, there is most likely a Servlet
>> SWC> TCK assertion for this. Mark, can you help us understand why you
>> SWC> are taking such a strong position against it as a representative
>> SWC> for the hugely important Tomcat community?
>>
>>>>>>> On Tue, 1 Sep 2015 19:19:45 +0100, Mark Thomas <markt_at_apache.org> said:
>>
>> MT> As I have said previously on this thread, web applications are meant
>> MT> to be independent of the context path at which they are
>> MT> deployed. Anything that encourages web application developers to
>> MT> think that they can code to a specific context path is a bad idea.
>>
>> May I paraphrase the spirit of your position as "don't make it any
>> easier than absolutely necessary to do bad things." While I agree with
>> the spirit of your position, in this case I think that spirit is trumped
>> by several factors, in decreasing order of importance.
>>
>> 1. many containers already offer this in a proprietary fashion
>>
>> 2. it sure would be convenient to offer it as a standard
>>
>> 3. we can put it at the bottom of a priority list, allowing the
>> preservation of out-of-webapp context-root specification
>>
>> 4. we can name the XML element sufficiently obviously to make it clear
>> the priority is below other ways of specifying the context-root.
>
> I think that it is also important to note that for full Java EE servers it
> is already possible to do this in application.xml.

And I'd agree that that is the right place for it.

Mark