The Java EE 6 Tutorial

Running the rsvp Example Application

Both NetBeans IDE and Ant can be used to deploy and run the rsvp example application.

ProcedureTo Run the rsvp Example Application in NetBeans IDE

  1. In NetBeans IDE, select File->Open Project.

  2. In the Open Project dialog, navigate to:


    tut-install/examples/jaxrs/
    
  3. Select the rsvp folder.

  4. Select the Open as Main Project check box.

  5. Click Open Project.

  6. Right-click the rsvp project in the left pane and select Run.

    The project will be compiled, assembled, and deployed to GlassFish Server. A web browser window will open to http://localhost:8080/rsvp.

  7. In the web browser window, click the Event Status link for the Duke’s Birthday event.

    You’ll see the current invitees and their responses.

  8. Click on the name of one of the invitees, select a response, and click Submit response; then click Back to event page.

    The invitee’s new status should now be displayed in the table of invitees and their response statuses.

ProcedureTo Run the rsvp Example Application Using Ant

Before You Begin

You must have started the Java DB database before running rsvp.

  1. In a terminal window, go to:


    tut-install/examples/jaxrs/rsvp
    
  2. Type the following command:


    ant all
    

    This command builds, assembles, and deploys rsvp to GlassFish Server.

  3. Open a web browser window to http://localhost:8080/rsvp.

  4. In the web browser window, click the Event Status link for the Duke’s Birthday event.

    You’ll see the current invitees and their responses.

  5. Click on the name of one of the invitees, select a response, and click Submit response, then click Back to event page.

    The invitee’s new status should now be displayed in the table of invitees and their response statuses.