Packaging an ADF Business Components Web Application for Deployment

A J2EE web module and its associated Business Components files can be packaged as a web archive (WAR file) or as separate components of an enterprise archive (EAR file). Once you've created the deployment profile and the appropriate deployment descriptor files, you can deploy the application to an application server, or as an archive file.

When you create a Business Components web application client such as a JSP, UIX JSP, or Struts JSP, JDeveloper automatically generates a J2EE web archive (WAR) deployment profile and its associated deployment descriptor file, web.xml, which defines the standard web application deployment descriptor parameters. Typically, a JSP client accesses the Business Components application in a J2EE web module configuration. The JSP client can also include data tags, data web beans, XSQL, tag libraries, and UIX tags to access the business components.

If your web application does not use Business Components, see Packaging a Web Application for Deployment.

To package a Business Components web application for deployment:

  1. (Optional) By default, Business Component files will be deployed in the web module. If you do not want to deploy your Business Components logic directly to the J2EE web module, deploy your business components as an EJB session bean.

  2. Create a web client application project containing your client application files.

  3. Choose the configuration that you want your application to use to connect to the deployed application module:

    1. Locate the DataBindings.cpx node in the client project folder. The Application Navigator displays the node in the Application Sources folder.
    2. Select the DataBindings.cpx node and display the Structure window.
    3. In the Structure window, expand the Data Controls node and select the AppModuleDataControl node.
    4. Open the Property Inspector and select the desired configuration from the dropdown list displayed in the Configuration field.

      For example, choosing <YourApplicationModule >Local would deploy the business logic to the web module. Choosing <YourApplicationModule >OracleAS or <YourApplicationModule >WLS instructs the JSP to use the business logic in the EJB session bean created in step 1.

  4. Create deployment profile for your project. To create a profile, right-click the web.xml node in the WEB-INF folder and choose Create WAR D eployment Profile. The WAR file deployment profile will appear in the Resources folder displayed in the Application Navigator.

    The web.xml file is created when you drop a databound component into your web page using the Data Control Palette. If the web.xml file it is not already present, add a web.xml deployment descriptor.

  5. (Optional) Edit the deployment profile. If the deployment profile depends on J2EE modules from another deployment profile, specify these dependencies on the profile's Profile Dependencies page. Thus, when the WAR is deployed to the target application server, the dependencies are also packaged with the WAR file in a single EAR file.

    1. (Optional) Profile Dependencies Page: if the deployment profile depends on J2EE modules from another deployment profile. JDeveloper lets you build a WAR deployment profile that can specify EJB JAR or WAR dependencies from other projects. Thus, when the WAR is deployed to the target application server, the corresponding dependencies are also packaged with the WAR file in a single Enterprise Archive (EAR) file.

    2. (Optional) Platform Subpage: JDeveloper lets you specify a default connection to be displayed in the context menu of the web application deployment profile, and lets you specify the target platform. You can also pass command line parameters to any of the supported target connection types.

  6. If the deployment target is Oracle Application Server or a standalone OC4J server, add an orion-web.xml deployment descriptor to your project, if it is not already present.

Notes:


About J2EE Deployment
About J2EE Archive Formats
About Deployment Profiles
About Deployment Descriptors
Packaging J2EE Applications
Deploying J2EE Applications
Deploying Applications to J2EE Application Servers

 

Copyright © 1997, 2004, Oracle. All rights reserved.