Dear RESTEasy team,
When working on a project using RESTEasy (using Jackson and JAX-RS) I noticed that when a class is annotated with @Produces isn't recognized (and thus it uses a default, in my case application/octet-stream). In the end this was because of a cached .class file somewhere, but in my debugging I found something that could be a bug (if it would be different it would have worked no matter of this cached file).
After some research I found that this was because the ServerResponseWriter class (link) has the following code:
What happens here though, is that the Method class is returned instead of the class that actually defines the method (the class that contains the annotation). I'd expect the method.getMethod().getDeclaringClass() here, which would return the class where it's defined (and which contains the @Produces annotation.
I assume this is unintended behavior, therefore I'm submitting a bug report here. If this is expected behavior, I apologize.