RESTEasy – Could not find MessageBodyWriter for response object of type:xx of media type: application/xml


Developing RESTEasy + JAXB provider to support XML, when return it back to client, it prompts following error message :

	Could not find MessageBodyWriter for response object of type: 
       of media type: application/xml
    at org.jboss.resteasy.core.ServerResponse.writeTo(
    at org.jboss.resteasy.core.SynchronousDispatcher.invoke(
    at org.jboss.resteasy.core.SynchronousDispatcher.invoke(


To use JAXB in RESTEasy, you need to include “resteasy-jaxb-provider.jar“.

		<id>JBoss repository</id>
Tags :

About the Author

Founder of and, love Java and open source stuff. Follow him on Twitter, or befriend him on Facebook or Google Plus. If you like my tutorials, consider make a donation to these charities.


  • Pingback: electricians bellingham wa()

  • Pingback: link()

  • Pingback: house blue()

  • Pingback: girl plumber crack pics()

  • Pingback: go to the website()

  • Pingback: locksmithing picks of the pole()

  • Pingback: electrician tool vest()

  • Pingback: website()

  • Pingback: water ionizer()

  • Pingback: pay per day loans plan()

  • Pingback: pay per day loan plans()

  • Pingback: stop parking()

  • Pingback: alkaline water()

  • Pingback: stop parking()

  • Pingback: laan penge()

  • Pingback: mobile porn()

  • Pingback: lan her og nu()

  • Pingback: Website()

  • Pingback:

  • Pingback: DIRECTV for your company()

  • Pingback: watch movies online free()

  • Pingback: Blue Coaster33()


  • praveen

    After Adding resteasy-jaxb-provider.jar File also i could see below Exception


    HTTP Status 500 – Could not find MessageBodyWriter for response object of type: of media type: application/json

  • Diganta

    Receiving the following error

    java.lang.RuntimeException: could not find writer for content-type application/json type: java.lang.String
    at org.jboss.resteasy.client.ClientRequest.writeRequestBody(
    at org.jboss.resteasy.client.core.executors.ApacheHttpClientExecutor$ClientRequestEntity.(
    at org.jboss.resteasy.client.core.executors.ApacheHttpClientExecutor.loadHttpMethod(
    at org.jboss.resteasy.client.core.executors.ApacheHttpClientExecutor.execute(
    at org.jboss.resteasy.client.ClientRequest.execute(
    at org.jboss.resteasy.client.ClientRequest.httpMethod(
    at com.resteasy.RESTEasyClientPost.main(

    • priya vincent

      still i face the linkage problem, after i add the resteasy-jaxb-provider also

      java.lang.LinkageError: JAXB 2.0 API is being loaded from the bootstrap classloader, but this RI (from jar:file:/D:/projects/jaxb/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/RESTfulExample/WEB-INF/lib/jaxb-impl-2.1.12.jar!/com/sun/xml/bind/v2/model/impl/ModelBuilder.class) needs 2.1 API. Use the endorsed directory mechanism to place jaxb-api.jar in the bootstrap classloader. (See

  • Pingback: JAX-RS Tutorial()