users@jersey.java.net

Re: [Jersey] why does jersey-core 1.4 contain all of jsr311?

From: Paul Sandoz <Paul.Sandoz_at_oracle.com>
Date: Thu, 28 Oct 2010 18:21:09 +0200

On Oct 28, 2010, at 6:15 PM, Ittay Dror wrote:
>>>>
>>>> But do you need to include the 311 jar in that environment?
>>> yes, i want to annotate classes with @Path without depending on
>>> jersey-core.
>>
>> Why do you need the 311 jar at runtime?
>
> it contains all the jax-rs annotations, e.g @Path. I annotate my
> classes which means @Path is resolved by one class loader, and
> jersey uses these annotations also which means they are resolved in
> its class loader. So from the JVM point of view these two @Path
> annotations are different entities.

But what i don't understand is why you require the 311 jar to be
present at runtime to any classloader?

I guess i don't understand what your environment is and whether it
requires the 311 jar to be present at runtime as opposed to just
compile time.

Paul.