RESTful Web Services Developer's Guide

ProcedureBuilding and Running the Bookstore Application from NetBeans IDE

  1. Select File->Open Project, and browse to the Jersey Bookstore sample application directory to open the project.

  2. Right-click the project and select Properties. On the Actions tab, make sure that Use external Maven for build execution is checked. Also on the Actions tab, select Run Project under Actions, then change the Execute Goals field to package glassfish:run, and change the Set Properties field to netbeans.deploy=true. On the Run tab, make sure that the server is set to GlassFish v3 Prelude.

  3. Right-click the project and select Run.

    This will build, package, and deploy the project onto GlassFish using Maven.

  4. In a web browser navigate to:


    http://localhost:8080/Bookstore/

    When the sample is running, it looks like the following example:


    URL: http://locahlhost:8080/Bookstore/
    Czech Bookstore
    
    Item List
    
    	* Svejk
    	* Krakatit
    	* Ma Vlast 1
    
    Others
    
    count inventory
    get the system time
    regular resources