users@glassfish.java.net

Re: javax.servlet API version?

From: Sahoo <sanjeeb.sahoo_at_oracle.com>
Date: Thu, 26 Apr 2012 13:30:44 +0530

On Wednesday 25 April 2012 09:08 PM, Laird Nelson wrote:
> On Wed, Apr 25, 2012 at 11:32 AM, Jason Lee <jason.d.lee_at_oracle.com
> <mailto:jason.d.lee_at_oracle.com>> wrote:
>
> I'm not entirely sure why there's a 3.1.1 of the API jar, but, and
> I could be wrong on this, I think 3.0.1, as Shing Wai points out,
> is the correct version, as there is no Servlet 3.1 yet (see JSR
> 340, http://jcp.org/en/jsr/detail?id=340).
>
>
> Exactly why I was confused. :-)
>
> Also, back in the day there were these incredibly annoying "API only"
> jars that broke things when you unit tested them. This isn't one of
> those, is it?
>
> Best,
> Laird
>
Didn't you notice the group id of the artifact which had version number
3.1.1? It must be org.glassfish. There is no universal API jar produced
for servlet spec. The API classes are a part of implementation of the
spec. So, we at glassfish have produced api jars that exclusively belong
to our namespace, compiled the way we like. They match version number of
our project as they are all released together.

Having said that some of us believe that since we are the Java EE RI, we
can claim namespaces like javax.blah.blah and produce jars like
javax.servlet:javax.servlet:3.0. This is why you will also find such
artifacts in maven repos. At no point, assume that there will be exactly
one artifact corresponding to one spec version. The artifacts may be
slightly changed to reflect fixes like types and other issues that might
have crept in in the process of reproducing the information from spec to
java source to classes. For more details, read the following which is an
outcome of numerous discussions that were held in internal archtecture
group of GlassFish:

https://wikis.oracle.com/display/GlassFish/Maven+Versioning+Rules

This is not yet completely implemented for all specs yet in our project.

Sahoo