This example demonstrates how to develop RESTful web service with CDI managed beans and Grizzly HTTP container.
To run this example in Grizzly HTTP server you just invoke the following from the command line:
mvn clean compile exec:java
We suggest you inspect the example source code to get better understanding on various CDI features utilized there. Following table contains some of the published resources that you might want to check.
Description URL Expected Results A hello-world managed bean http://localhost:8080/weld/helloworld?name=BillHello BillApplication scoped resource http://localhost:8080/weld/app/countrequest count (incremented with every other request)Request scoped resource http://localhost:8080/weld/req/app/counterlinks to above request counterAsynchronous echo resource method that is being JAX-RS intercepted http://localhost:8080/weld/req/parameterized-async?q=echo%20thisecho this