users@jersey.java.net

Re: Inheritance of Annotations and Jersey?

From: Martin Probst <mail_at_martin-probst.com>
Date: Wed, 8 Jul 2009 15:24:38 +0200

> I just discovered (...in the hard way...) that annotations are not
> inherited in JAX-RS/Jersey.

To be a bit more precise, there is the meta-annotation @Inherited,
which is present on @Produces and on @Consumes, but not on the other
jax-rs annotations.

But @Inherited is not sufficient to really get transparent inheritance
of annotations, as it doesn't work with implementing interfaces, and
it only works for annotations on classes, not for annotations on
methods.

Pretty weird if you ask me.

Martin