2 Replies Latest reply on Mar 13, 2009 4:15 PM by pragun1

    Seam-RESTEasy sample

    chuaky

      hi any1,


      Would appreciate advice on how to get a simple RESTEasy to work for beginners.  I tried to follow the instructions on Chapter 24.4.1 of Seam 2.1.1 reference manual to setup a simple RESTEasy sample.


      I use the seam booking example to add the RESTEasy sample and encountered this error when i use the GET request via:



      http://localhost:8080/seam/resource/rest/customer/123

      The error i got is:



      The requested resource (/seam/resource/rest/customer/123) is not available.


      @Path("/customer")
      public class MyCustomerResource {
      @GET
      @Path("/{customerId}")
      @ProduceMime("text/plain")
      public String getCustomer(@PathParam("customerId") int id) {
      
      return "hello";
      }
      }




      Thank you.

        • 1. Re: Seam-RESTEasy sample
          chuaky

          hi all,


          I use the wrong url, the correct one should be:



          http://localhost:8080/seam-booking/seam/resource/rest/customer/123

          Sorry for the inconvenience.
          Best regards.

          • 2. Re: Seam-RESTEasy sample

            Hi Chua,


            I am also a begginers in Seam RESTEasy. I have gone through Seam 2.1.1GA Reference Chapter-24. I want to build a sample RESTEasy WebServices from Seam examples.


            Could you please describe the steps which you carried out to build Seam Booking example for RESTEasy implementation?


            Thanks in advance.