background image
<< Deploying a Database Application | Exporting the Database Objects >>
<< Deploying a Database Application | Exporting the Database Objects >>

Planning for Deployment

Planning for Deployment
7-2 Oracle Database 2 Day Developer's Guide
Step 1: Create a Test Environment
You should always have a test environment, for the initial deployment, for thorough
testing of the application before it is deployed in any other environment, and perhaps
also for training of application users.
Testing checks both the functionality of your application and whether you have
packaged it correctly. If you have missed an object that your application depends
upon, you can catch it during testing rather than after it is deployed to actual users in
the production environment.
Step 2: Create a Quality Assurance (QA) Environment
If the application is sufficiently complex and if you have the resources, create a QA
environment in which changes to the system can be checked in a rigorous manner.
Step 3: Create an Education Environment
An education environment enables you to provide training and practice, for internal or
external users, without affecting any of the other environments. You can create the
education environment before or after the production environment, and you can
update it independently of updates to other environments.
Step 4: Create the Production Environment
The production environment contains the actual data and database objects for the
normal operation of your organization. Test any objects in the test environment before
you move them into the production environment.
Regardless of how the number of environments to which you deploy, the deployment
process is the same.
Planning for Deployment
Before you deploy an application, you must understand the dependencies between the
database objects. You must create the objects in the correct order, so that if any objects
depend on other objects, the dependent objects exist in each case. If a dependent object
is missing, an error or problem such as the following will occur:
The
CREATE
statement will fail, such as with constraints.
The object will be created but left in an invalid state, such as with functions,
procedures, and packages.
To deploy data, you can take one of the following approaches with the data for each
table, depending on how confident you are of the validity of the data:
Load the data without worrying about any possible validity issues.
You can use this approach if you are confident you are of the following: the data
will not violate any constraint, no duplicate values exist in primary key and
unique key columns, all foreign key references will already exist, and the data in
any column governed by a check constraint meets that constraint. For example, if
you are simply loading lookup data from your development environment, and
load your data in a proper order, the constraints will not need to be disabled
because the constraints will not be violated.
Disable all constraints before you load the data, and then enable the constraints
after the data loading is complete.
If you want to load data without needing to sequence it (such as when you have
many tables to load and much dependent data) or if you will be loading data from