Translate

14 Nisan 2016 Perşembe

HTTP 404 Not Found

Reason:

You may faced with by making call  POST ,PUT,DELETE operations .
GET request won't be problem.

Solution:

Content-Type: application/json

If you have java REST client or  another clients tool like POSTMAN,

You should add this parameter in headers






I had Request param like below .

@WebService
@Path("/tasks")
@Consumes({ "application/json", "application/xml" })
@Produces({ "application/json", "application/xml" })
public interface TaskWs {

@PUT
@Path("/update/deneme/{id}")
public Response updateTask(@PathParam("id") Long id,TaskDto taskDto);
   .
   . 
}
but implementation side I had 


public Response updateTask(@PathParam("id") Long id,TaskDto taskDto) {
return null;
}

 I deleted @PathParam("id") 

so 
 I had now this code .
public Response updateTask(Long id,TaskDto taskDto) {
return null;

Hiç yorum yok:

Yorum Gönder

Bu Blogda Ara