Hi Fernando,
did you create an implementation of the Application-Class and Annotated
it with @ApplicationPath? That is how I have always done it.
I believe you need to create some Servlet mappings otherwise, maybe have
a look at
https://jakarta.ee/specifications/restful-ws/3.0/jakarta-restful-ws-spec-3.0#servlet
~ Benedict
Am 30.09.24 um 22:28 schrieb Fernando:
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