[Jersey] Jersey not working while running on root context

From: Sigmar Muuga <>
Date: Mon, 12 Sep 2011 11:07:56 +0300


I have the following problem:

When deploying the app to the context root (/), message body writers stop
working. I get errors like "Caused by: com.sun.jersey.api.MessageException:
A message body writer for Java class and MIME media type
application/xml was not found"

When running the app in localhost, with maven jetty plugin and having the
context path /myapp it all works.

I googled around and read the docs but I don't have any idea, what may be
wrong here...