Simple REST doesn't work
Fernando <[email protected]> Mon, 30 Sep 2024 17:28:45 -0300
| Newsgroups | gmane.comp.java.openejb.user |
|---|---|
| Message-ID | <CAMzbw58-CqUbTNxiZRBStXT=pyxRw55snJ7FfrN0+ciM=jv18w__5837.59407033853$1727728155$gmane$org@mail.gmail.com> |
Hi all!,
I am trying to implement a very simple rest web service following the guide:
https://tomee.apache.org/tomee-8.0/examples/simple-rest.html
and this is my code:
@Path(" articuloservice ")
public class ArticulosService {
@Inject
private ArticuloDao articuloDao;
@GET
@Path("/saludar")
@Produces(MediaType.TEXT_PLAIN)
public String Saludo() {
return "Helloooo!";
}
}
I am trying to test the code using postman (GET) :
*http://localhost:8080/Hiper/articuloservice/saludar
<http://localhost:8080/Hiper/articuloservice/saludar>*
getting the following response: "*The required resource is not available*"
Maybe I am missing something?...any idea?
Thanks in advance!
Fernando