title: Jersey REST get returns java.lang.NoSuchMethodError
body: <p>I'm trying to get a response from a working REST webservice.</p>
  
  <p>I have come up with the following looking at the documentation:</p>
  
  <pre><code>void postRest()
  {
      Client client = ClientBuilder.newClient();
      WebTarget webTarget = client.target("http://localhost:8080/TestApplication/");
      WebTarget resourceWebTarget = webTarget.path("webresources");
      WebTarget peopleWebTarget = resourceWebTarget.path("people/get/all");
  
      Invocation invocation = peopleWebTarget.request("text/xml").header("Content-Type", "application/xml").buildGet();
      String response = invocation.invoke(String.class);
  
      System.out.println(response);
  }
  </code></pre>
  
  <p>However I am returned a not very friendly:</p>
  
  <pre><code>Exception in thread "main" java.lang.NoSuchMethodError: org.glassfish.jersey.message.internal.MessagingBinders$MessageBodyProviders.&lt;init&gt;(Ljava/util/Map;Ljavax/ws/rs/RuntimeType;)V
      at org.glassfish.jersey.client.ClientBinder.configure(ClientBinder.java:118)
      at org.glassfish.hk2.utilities.binding.AbstractBinder.bind(AbstractBinder.java:169)
      at org.glassfish.jersey.internal.inject.Injections.bind(Injections.java:157)
      at org.glassfish.jersey.internal.inject.Injections._createLocator(Injections.java:147)
      at org.glassfish.jersey.internal.inject.Injections.createLocator(Injections.java:137)
      at org.glassfish.jersey.client.ClientConfig$State.initRuntime(ClientConfig.java:352)
      at org.glassfish.jersey.client.ClientConfig$State.access$000(ClientConfig.java:85)
      at org.glassfish.jersey.client.ClientConfig$State$3.get(ClientConfig.java:117)
      at org.glassfish.jersey.client.ClientConfig$State$3.get(ClientConfig.java:114)
      at org.glassfish.jersey.internal.util.collection.Values$LazyValue.get(Values.java:275)
      at org.glassfish.jersey.client.ClientConfig.getRuntime(ClientConfig.java:669)
      at org.glassfish.jersey.client.ClientRequest.getConfiguration(ClientRequest.java:276)
      at org.glassfish.jersey.client.JerseyInvocation.validateHttpMethodAndEntity(JerseyInvocation.java:124)
      at org.glassfish.jersey.client.JerseyInvocation.&lt;init&gt;(JerseyInvocation.java:97)
      at org.glassfish.jersey.client.JerseyInvocation.&lt;init&gt;(JerseyInvocation.java:90)
      at org.glassfish.jersey.client.JerseyInvocation$Builder.buildGet(JerseyInvocation.java:201)
      at org.glassfish.jersey.client.JerseyInvocation$Builder.buildGet(JerseyInvocation.java:154)
      at client.RestClient.postRest(RestClient.java:24)
      at client.RestClient.main(RestClient.java:14)
  Java Result: 1
  </code></pre>
  
  <p>I'm using NetBeans and didn't add any library as it seems the GlassFish Server comes with
  javax.ws.rs-api.jar which make the above run.</p>
  
  <p>Do I need to add Jersey.jar as well inside libraries or am I missing something?
  Thank you</p>