First of all, discard everything you wrote in web.xml
. On GlassFish (and all JavaEE 7 containers) JAX-RS works out of the box, no configuration needed.
Then you must have in your classpath a javax.ws.rs.core.Application
subclass, declaring an @ApplicationPath("/")
(this tells the container to start the JAX-RS engine).
The other resources will be picked up automatically by the Application Server.`