How to do a POST request with QueryParam
<p>I have a method in my rest interface which looks like this:</p>

<pre><code>@POST
@Path("/path/{param1}/{param2}")
@Consumes(MediaType.APPLICATION_JSON)
@Produces(MediaType.APPLICATION_JSON)
Response updateData(@PathParam("param1") String param1,
                       @PathParam("param2") String param2,
                       String dataPointJson);
</code></pre>

<p>I'm trying without success to do a post request, here's my code:</p>

<pre><code>WebTarget path = collect.path("/path/someParam1/" + someParam2);
    Data dp = new Data.Builder()               
    Response post = path.request().post(Entity.json(dp));
</code></pre>

<p>Every time I get a 404 response:</p>

<pre><code>ClientResponse{method=POST, uri=http://localhost:9090/collect/path/someParam1/someParam2, status=404, reason=Not Found}
</code></pre>

<p>Can someone please suggest what I'm doing wrong? Tried different combinations of "consumes"/"produces", also tried all examples from tutorials which I found on the net. </p>