Run the JSP Application

Run the TemperatureConverterJsp application on JBoss 7.1.1.
  1. In the Project Explorer, right-click the TemperatureConverterPrj project; then select Run As > Run on Server from the context menu.
  2. On the Run On Server dialog box, be sure that JBoss AS 7.1 is selected; then click Finish.

    Eclipse generates an HTTP Status 404 message, indicating that it is unable to find the http://localhost:8080/TemperatureConverterPrj/ URL. This is expected because the application uses two different URLs to call the two conversion routines with arguments.

    Eclipse has a built-in browser window that opens when the server is started, but you can use any external browser to enter the URLs.

  3. In the Eclipse browser address field, enter the following to run the Fahrenheit to Celsius conversion:

    Eclipse presents a .json file dialog box.

  4. Click Open to view the results of the method call.
  5. Repeat steps 3 and 4, substituting the following URL to test the Celsius to Fahrenheit conversion:
    Note: You can change the values of the fahrenheit and celsius arguments to see different results.
  6. To test in an external browser, open a browser of your choice; then enter each of the same URLs.

    Depending on your browser, the results are either returned in the browser or you are prompted to save the results to a text file.