5-2 Deploying Applications to Oracle WebLogic Server
■
To expose the external resources requirements of the application as null variables in a deployment plan.
Any external resources required by the application are subject to change when the application is deployed to a different
environment. For example, the JNDI names of datasources used in your development environment may be different from those used in testing or
production. Exposing those JNDI names as variables makes it easy for deployers to use available resources or create required resources when deploying the
application. Using empty null variables forces the deployer to fill in a valid resource name before the application can be deployed.
■
To expose additional configurable properties, such as tuning parameters, as variables in a deployment plan.
Certain tuning parameters that are acceptable in a development environment may be unacceptable in a production environment.
For example, it may suffice to accept default or minimal values for EJB caching on a development machine, whereas a production cluster would need higher levels of
caching to maintain acceptable performance. Exporting selected tunables as deployment plan variables helps an administrator focus on important tuning
parameters when deploying the application. The Administration Console highlights tuning parameters exposed as variables in a deployment plan, but does
not require a deployer to modify them before deployment.
5.1.2 Tools for Exporting a Deployment Configuration
WebLogic Server provides the following tools to help you export an applications deployment configuration:
■
weblogic.PlanGenerator creates a template deployment plan with null variables for selected categories of WebLogic Server deployment descriptors. This
tool is recommended if you are beginning the export process and you want to create a template deployment plan with null variables for an entire class of
deployment descriptors see
Section 5.2, Understanding Deployment Property Classifications
. You typically need to manually modify the deployment plan created by weblogic.PlanGenerator, either manually or using the
Administration Console, to delete extraneous variable definitions or add variables for individual properties.
■
The Administration Console updates or creates new deployment plans as necessary when you change configuration properties for an installed application.
You can use the Administration Console to generate a new deployment plan or to add or override variables in an existing plan. The Administration Console
provides greater flexibility than weblogic.PlanGenerator, because it allows you to interactively add or edit individual deployment descriptor properties in the
plan, rather than export entire categories of descriptor properties.
5.2 Understanding Deployment Property Classifications
Each WebLogic Server deployment descriptor property for all J2EE module descriptors as well as JDBC, JMS, and WLDF application modules can be classified
into one of the following categories:
■
Non-configurable properties cannot be changed by an administrator during a deployment configuration session. Non-configurable properties are used to
describe application behavior that is fundamental to the basic operation of the application. For example, the ejb-name property is categorized as
non-configurable, because changing its value also requires changing the EJB application code.
Exporting an Application for Deployment to New Environments 5-3
■
Dependency properties resolve resource dependencies defined in the J2EE deployment descriptors. For example, if the J2EE descriptor for an EJB defines a
datasource name that is used within the EJB code, the WebLogic Server descriptor uses a dependency property to bind the datasource name to an actual datasource
configured in the target WebLogic Server domain.
■
Declaration properties declare a resource that other applications can use. For example, the JNDI name of an EJB declares the EJB name that other applications or
modules would use to access the EJB.
■
Configurable properties are the remaining properties not classified as dependency or declaration properties. Generally configurable properties enable or configure
WebLogic Server-specific features and tuning parameters for the deployed application. For example, the WebLogic Server descriptor for an EJB might define
the number of EJBs that WebLogic Server caches in memory.
Use these categories during the configuration export process to select properties to expose as variables in the deployment plan. For example, a developer can generate a
new deployment plan containing variable definitions for all properties tagged as dependencies in an applications WebLogic Server deployment descriptors. The
variables can then be easily changed by an administrator deploying the application to an environment having different resource names.
All changeable descriptor properties dependency, declaration, and configurable properties are further classified as either dynamic or non-dynamic properties. Dynamic
properties can be changed in a deployed application without requiring you to redeploy for the changes to take effect. Non-dynamic properties can be changed but
require redeployment for the changes to take effect. The Administration Console identifies non-dynamic properties as a reminder for when redeployment is necessary.
5.3 Steps for Exporting an Applications Deployment Configuration