Stack Exchange
java sample rest program
i was trying sample rest server application. 
i was getting 404 every time i try to access the server.
code detail:-
Application(war) name :- Rest
Service class:
package com.sandeepjn.rest.service;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.core.Response;
@Path("/services")
public class EmployeeService {
    @GET
    @Path("/{param}")
     public Response sayHello() {
        String str ="working";         
        return Response.status(200).entity(str).build(); 
    }
}

Web-inf:-
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="3.0" xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
    <display-name>Rest</display-name>
    <servlet>
        <servlet-name>jersey-servlet</servlet-name>
        <servlet-class>org.glassfish.jersey.servlet.ServletContainer</servlet-class>
        <init-param>
            <param-name>jersey.config.server.provider.packages</param-name>
            <param-value>com.sandeepjn.rest.service</param-value>
        </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>jersey-servlet</servlet-name>
        <url-pattern>/rest/*</url-pattern>
    </servlet-mapping>
</web-app>

URl used for testing:-
http://localhost:8080/Rest/rest/services/data

Using this i am always getting 404. 

Have you tried? http://localhost:8080/rest/services/data

Yes. Same result 404.

An if you drop the slash in @Path("/{param}") => @Path("{param}")?

Why not take this example as a starting point... http://www.mkyong.com/webservices/jax-rs/jax-rs-path-uri-matching-example/

Thanks for the solutions. it worked for me now. during deployment, web.xml was not be exploded properly.
