Modifying the Java EE Application (original) (raw)

Modifying the Java EE Application

The Application Server supports iterative development. Whenever you make a change to a Java EE application, you must redeploy the application.

Modifying a Class File

To modify a class file in an enterprise bean, you change the source code, recompile it, and redeploy the application. For example, if you want to change the exchange rate in the dollarToYen business method of the ConverterBean class, you would follow these steps.

  1. Edit ConverterBean.java.
  2. Recompile ConverterBean.java.
    1. In a terminal window, go to the tut-install/javaeetutorial5/examples/ejb/converter/ subdirectory.
    2. Type the following command:
      ant
      This command runs the default task, which repackages the entire application (application client, enterprise bean JAR, and web client).
  3. Type the following command:
    ant deploy

To modify the contents of a WAR file, or to modify the application client, follow the preceding steps.

Copyright © 2010, Oracle and/or its affiliates. All rights reserved. Legal Notices