Oracle® Application Development Framework Developer's Guide
10g Release 3 (10.1.3) B25386-01 |
|
![]() Previous |
![]() Next |
Before you can deploy applications that use ADF on third-party application servers, you need to install the ADF runtime libraries on those application servers. You can perform the installation using a wizard or you can do it manually:
For WebLogic, JBoss, and Tomcat, you can install the ADF runtime libraries from JDeveloper using the ADF Runtime Installer wizard. See Section 22.12.1, "Installing the ADF Runtime Libraries from JDeveloper".
For WebSphere, you have to install the ADF runtime libraries manually. See Section 22.12.2, "Configuring WebSphere 6.0.1 to Run ADF Applications".
For all application servers, you can install the ADF runtime libraries manually. See Section 22.12.3, "Installing the ADF Runtime Libraries Manually".
You can install the ADF runtime libraries from JDeveloper on selected application servers. The supported application servers are listed in the Tools > ADF Runtime Installer submenu.
Note that for WebSphere, you need to install the libraries manually. See Section 22.12.2, "Configuring WebSphere 6.0.1 to Run ADF Applications".
To install the ADF Runtime Libraries from JDeveloper:
Stop all instances of the target application server.
(WebLogic only) Create a new WebLogic domain, if you do not already have one. You will install the ADF runtime libraries in the domain.
Steps for creating a domain in WebLogic are provided here for your convenience.
Note: The domain must be configured to use Sun's JDK. |
Steps for Creating Domains in WebLogic 8.1:
From the Start menu, choose Programs > BEA WebLogic Platform 8.1 > Configuration Wizard. This starts up the Configuration wizard.
On the Create or Extend a Configuration page, select Create a new WebLogic Configuration. Click Next.
On the Select a Configuration Template page, select Basic WebLogic Server Domain. Click Next.
On the Choose Express or Custom Configuration page, select Express. Click Next.
On the Configure Administrative Username and Password page, enter a username and password. Click Next.
On the Configure Server Start Mode and Java SDK page, make sure you select Sun's JDK. Click Next.
On the Create WebLogic Configuration page, you can change the domain name. For example, you might want to change it to jdevdomain
.
Steps for Creating Domains in WebLogic 9.0:
From the Start menu, choose Programs > BEA Products > Tools > Configuration Wizard. This starts up the Configuration wizard.
On the Welcome page, select Create a new WebLogic Domain. Click Next.
On the Select a Domain Source page, select Generate a domain configured automatically to support the following BEA products. Click Next.
On the Configure Administrator Username and Password page, enter a username and password. Click Next.
On the Configure Server Start Mode and JDK page, make sure you select Sun's JDK. Click Next.
On the Customize Environment and Services Settings page, select No. Click Next.
On the Create WebLogic Domain page, set the domain name. For example, you might want to set it to jdevdomain
. Click Create.
Start the ADF Runtime Installer wizard by choosing Tools > ADF Runtime Installer > Application_Server_Type. Application_Server_Type is the type of the target application server (for example, Oracle Application Server, WebLogic, JBoss, or standalone OC4J).
Proceed through the pages in the wizard. For detailed instructions for any page in the wizard, click Help. You need to enter the following information in the wizard:
On the Home Directory page, select the home or root directory of the target application server.
(WebLogic only) On the Domain Directory page, select the home directory of the WebLogic domain where you want to install the ADF libraries. You created this domain in step 2.
On the Installation Options page, choose Install the ADF Runtime Libraries.
On the Summary page, check the details and click Finish.
(WebLogic only) Edit WebLogic startup files so that WebLogic includes the ADF runtime library when it starts up.
Steps for WebLogic 8.1:
Make a backup copy of the WEBLOGIC_HOME\user_projects\domains\jdevdomain\startWebLogic.cmd
(or startWebLogic.sh
) file because you will be editing it in the next step. "jdevdomain
" is the name of the domain that you created earlier in step 2.
In the startWebLogic.cmd
(or startWebLogic.sh
) file, add the "call "setupadf.cmd"
" line (for Windows) before the "set
CLASSPATH
" line:
call "setupadf.cmd"
set CLASSPATH=%WEBLOGIC_CLASSPATH%;%POINTBASE_CLASSPATH%;
%JAVA_HOME%\jre\lib\rt.jar;%WL_HOME%\server\lib\webservices.jar;
%CLASSPATH%
The setupadf.cmd
script was installed by the ADF Runtime Installer wizard in the WEBLOGIC_HOME\user_projects\domains\jdevdomain
directory.
To start WebLogic, change directory to the jdevdomain
directory and run startWebLogic.cmd
:
> cd WEBLOGIC_HOME\user_projects\domains\jdevdomain > startWebLogic.cmd
Steps for WebLogic 9.0:
Make a backup copy of the %DOMAIN_HOME%\bin\setDomainEnv.cmd
file because you will be editing it in the next step.
%DOMAIN_HOME%
is specified in the startWebLogic.cmd
(or startWebLogic.sh
) file. For example, if you named your domain jdevdomain
, then %DOMAIN_HOME%
would be BEA_HOME\user_projects\domains\jdevdomain
. You created the domain earlier in step 2.
In the %DOMAIN_HOME%\bin\setDomainEnv.cmd
file, add the "call "%DOMAIN_HOME%\setupadf.cmd"
" line before the "set
CLASSPATH
" line:
call "%DOMAIN_HOME%\setupadf.cmd" set CLASSPATH=%PRE_CLASSPATH%;%WEBLOGIC_CLASSPATH%;%POST_CLASSPATH%; %WLP_POST_CLASSPATH%;%WL_HOME%\integration\lib\util.jar;%CLASSPATH%
If the "set CLASSPATH" line does not have %CLASSPATH%
, then add it to the line, as shown above.
To start WebLogic, change directory to %DOMAIN_HOME%
and run startWebLogic.cmd
:
> cd %DOMAIN_HOME% > startWebLogic.cmd
(WebLogic only) Before you run JDeveloper, configure JDeveloper to include the WebLogic client in its class path.
Make a backup copy of the JDEVELOPER_HOME\jdev\bin\jdev.conf
file because you will be editing it in the next step.
Add the following line to the jdev.conf
file:
AddJavaLibFile <WEBLOGIC_HOME>\server\lib\weblogic.jar
Replace <WEBLOGIC_HOME>
with the fullpath to the directory where you installed WebLogic.
Restart the target application server. If you are running WebLogic, you may have already started up the server.
Managing Multiple Versions of the ADF Runtime Library
Application servers may contain different versions of the ADF runtime libraries, but at any time only one version (the active version) is accessible to deployed applications. The other versions are archived.
You can use the ADF Runtime Installer wizard to make a different version the active version. On the Installation Options page in the wizard, choose the Restore option.
Before you can run ADF applications on WebSphere 6.0.1, you have to perform these steps:
Create the install_adflibs_1013.sh
(or .cmd
on Windows) script, as follows:
If you are running on UNIX:
Copy the source shown in Section 22.12.2.1, "Source for install_adflibs_1013.sh Script" and paste it to a file. Save the file as install_adflibs_1013.sh
.
Enable execute permission on install_adflibs_1013.sh
.
> chmod a+x install_adflibs_1013.sh
If you are running on Windows, copy the source shown in Section 22.12.2.2, "Source for install_adflibs_1013.cmd Script" and paste it to a file. Save the file as install_adflibs_1013.cmd
.
You will run the script later, in step 3.
Stop the WebSphere processes.
Run the install_adflibs_1013.sh
(.cmd
on Windows) script to install the ADF libraries, as follows:
Set the ORACLE_HOME environment variable to point to the JDeveloper installation.
Set the WAS_ADF_LIB environment variable to point to the location where you want to install the ADF library files. Typically this is the WebSphere home directory. The library files are installed in the WAS_ADF_LIB/lib
and WAS_ADF_LIB/jlib
directories.
Run the script. <script_dir>
refers to the directory where you created the script.
> cd <script_dir>
> install_adflib_1013.sh // if on Windows, use the .cmd extension
Start WebSphere processes.
Use the WebSphere administration tools to create a new shared library. Depending on your application, you create one of the shared libraries below.
For applications that use Oracle SQL flavor and type map, create the ADF10.1.3-Oracle shared library:
Set the name of the shared library to ADF10.1.3-Oracle
.
Set the classpath to include all the JAR files in WAS_ADF_LIB\lib
and WAS_ADF_LIB\jlib
except for WAS_ADF_LIB\jlib\bc4jdomgnrc.jar
. This JAR file is used for generic type mappings.
WAS_ADF_LIB
refers to the directory that will be used as a library defined in the WebSphere console. WAS_ADF_LIB
contains the ADF library files.
For applications that use non-Oracle SQL flavor and type map, create the ADF10.1.3-Generic shared library:
Set the name of the shared library to ADF10.1.3-Generic
.
Set the classpath to include WAS_ADF_LIB\jlib\bc4jdomgnrc.jar
and all the JAR files in WAS_ADF_LIB\lib
except for bc4jdomorcl.jar
. WAS_ADF_LIB
refers to the directory that will be used as a library defined in the WebSphere console. WAS_ADF_LIB
contains the ADF library files.
Add the following parameter in the Java command for starting up WebSphere.
-Djavax.xml.transform.TransformerFactory=org.apache.xalan.processor.TransformerFactoryImpl
Shut down and restart WebSphere so that it uses the new parameter.
Example 22-1 shows the source for the install_adflibs_1013.sh
script. Instead of copying the ADF runtime library files manually to your WebSphere environment, you can use this script. See Section 22.12.2, "Configuring WebSphere 6.0.1 to Run ADF Applications" for details.
The install_adflibs_1013.sh
script is for use on UNIX environments. If you are running on Windows, see Section 22.12.2.2, "Source for install_adflibs_1013.cmd Script".
Example 22-1 install_adflibs_1013.sh
#!/bin/sh EXIT=0 if [ "$ORACLE_HOME" = "" ] then echo "Error: The ORACLE_HOME environment variable must be set before executing this script." echo "This should point to your JDeveloper installation directory" EXIT=1 fi if [ "$WAS_ADF_LIB" = "" ]; then echo "Error: The WAS_ADF_LIB environment variable must be set before executing this script." echo "This should point to the location where you would like the ADF jars to be copied." EXIT=1 fi if [ "$EXIT" -eq 0 ] then if [ ! -d $WAS_ADF_LIB ]; then mkdir $WAS_ADF_LIB fi if [ ! -d $WAS_ADF_LIB/lib ]; then mkdir $WAS_ADF_LIB/lib fi if [ ! -d $WAS_ADF_LIB/jlib ]; then mkdir $WAS_ADF_LIB/jlib fi # Core BC4J runtime cp $ORACLE_HOME/BC4J/lib/adfcm.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/adfm.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/adfmweb.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/adfshare.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jct.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jctejb.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jdomorcl.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jimdomains.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jmt.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/lib/bc4jmtejb.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/jlib/dc-adapters.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/jlib/adf-connections.jar $WAS_ADF_LIB/lib/ # Core BC4J jlib runtime cp $ORACLE_HOME/BC4J/jlib/bc4jdomgnrc.jar $WAS_ADF_LIB/jlib/ cp $ORACLE_HOME/BC4J/jlib/adfui.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/BC4J/jlib/adfmtl.jar $WAS_ADF_LIB/lib/ # Oracle Home jlib runtime cp $ORACLE_HOME/jlib/jdev-cm.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/jlib/jsp-el-api.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/jlib/oracle-el.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/jlib/commons-el.jar $WAS_ADF_LIB/lib/ # Oracle MDS runtime cp $ORACLE_HOME/jlib/commons-cli-1.0.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/jlib/xmlef.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/mds/lib/mdsrt.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/mds/lib/concurrent.jar $WAS_ADF_LIB/lib/ # Oracle Diagnostic cp %ORACLE_HOME%/diagnostics/lib/commons-cli-1.0.jar $WAS_ADF_LIB/lib/ # SQLJ Runtime cp $ORACLE_HOME/sqlj/lib/translator.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/sqlj/lib/runtime12.jar $WAS_ADF_LIB/lib/ # Intermedia Runtime cp $ORACLE_HOME/ord/jlib/ordhttp.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/ord/jlib/ordim.jar $WAS_ADF_LIB/lib/ # Toplink cp $ORACLE_HOME/toplink/jlib/toplink.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/toplink/jlib/antlr.jar $WAS_ADF_LIB/lib/ # OJMisc cp $ORACLE_HOME/jlib/ojmisc.jar $WAS_ADF_LIB/lib/ # XML Parser cp $ORACLE_HOME/lib/xmlparserv2.jar $WAS_ADF_LIB/lib/ # JDBC cp $ORACLE_HOME/jdbc/lib/ojdbc14.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/jdbc/lib/ojdbc14dms.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/lib/dms.jar $WAS_ADF_LIB/lib/ # XSQL Runtime cp $ORACLE_HOME/lib/xsqlserializers.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/lib/xsu12.jar $WAS_ADF_LIB/lib/ cp $ORACLE_HOME/lib/xml.jar $WAS_ADF_LIB/lib/ fi
Example 22-2 shows the source for the install_adflibs_1013.cmd
script. Instead of copying the ADF runtime library files manually to your WebSphere environment, you can use this script. See Section 22.12.2, "Configuring WebSphere 6.0.1 to Run ADF Applications" for details.
The install_adflibs_1013.cmd
script is for use on Windows environments. If you are running on UNIX, see Section 22.12.2.1, "Source for install_adflibs_1013.sh Script".
Example 22-2 install_adflibs_1013.cmd
@echo off if {%ORACLE_HOME%} =={} goto :oracle_home if {%WAS_ADF_LIB%} =={} goto :was_adf_lib mkdir %WAS_ADF_LIB% mkdir %WAS_ADF_LIB%\lib mkdir %WAS_ADF_LIB%\jlib @REM Core BC4J runtime copy %ORACLE_HOME%\BC4J\lib\adfcm.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\adfm.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\adfmweb.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\adfshare.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jct.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jctejb.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jdomorcl.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jimdomains.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jmt.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\bc4jmtejb.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\collections.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\lib\adfbinding.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\jlib\dc-adapters.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\jlib\adf-connections.jar %WAS_ADF_LIB%\lib\ @REM Core BC4J jlib runtime copy %ORACLE_HOME%\BC4J\jlib\bc4jdomgnrc.jar %WAS_ADF_LIB%\jlib\ copy %ORACLE_HOME%\BC4J\jlib\adfui.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\BC4J\jlib\adfmtl.jar %WAS_ADF_LIB%\lib\ @REM Oracle Home jlib runtime copy %ORACLE_HOME%\jlib\jdev-cm.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\jlib\jsp-el-api.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\jlib\oracle-el.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\jlib\commons-el.jar %WAS_ADF_LIB%\lib\ @REM Oracle MDS runtime copy %ORACLE_HOME%\jlib\commons-cli-1.0.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\jlib\xmlef.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\mds\lib\mdsrt.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\mds\lib\concurrent.jar %WAS_ADF_LIB%\lib\ @REM Oracle Diagnostic copy %ORACLE_HOME%\diagnostics\lib\ojdl.jar %WAS_ADF_LIB%\lib\ @REM SQLJ Runtime copy %ORACLE_HOME%\sqlj\lib\translator.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\sqlj\lib\runtime12.jar %WAS_ADF_LIB%\lib\ @REM Intermedia Runtime copy %ORACLE_HOME%\ord\jlib\ordhttp.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\ord\jlib\ordim.jar %WAS_ADF_LIB%\lib\ @REM Toplink copy %ORACLE_HOME%\toplink\jlib\toplink.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\toplink\jlib\antlr.jar %WAS_ADF_LIB%\lib\ @REM OJMisc copy %ORACLE_HOME%\jlib\ojmisc.jar %WAS_ADF_LIB%\lib\ @REM XML Parser copy %ORACLE_HOME%\lib\xmlparserv2.jar %WAS_ADF_LIB%\lib\ @REM JDBC copy %ORACLE_HOME%\jdbc\lib\ojdbc14.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\jdbc\lib\ojdbc14dms.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\lib\dms.jar %WAS_ADF_LIB%\lib\ @REM XSQL Runtime copy %ORACLE_HOME%\lib\xsqlserializers.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\lib\xsu12.jar %WAS_ADF_LIB%\lib\ copy %ORACLE_HOME%\lib\xml.jar %WAS_ADF_LIB%\lib\ goto :end :oracle_home @echo Set the ORACLE_HOME pointing to the directory of your 10.1.3 JDeveloper installation. :was_adf_lib if {%WAS_ADF_LIB%} =={} @echo Set the WAS_ADF_LIB environment variable pointing to the directory where you would like to install ADF libraries. :end
Instead of using the ADF Runtime Installer wizard in JDeveloper to install the libraries, you can also install the libraries manually on your target application server.
Table 22-8 lists the files that you must copy to your application server before you deploy any ADF applications. In the table, JDEV_INSTALL
refers to the directory where you installed JDeveloper.
The destination directory (the directory to which you copy these files) depends on your application server:
For JBoss, the destination directory is JBOSS_HOME/server/default/lib
.
For WebLogic, the destination directory is WEBLOGIC_HOME/ADF/lib
. You have to create the ADF
directory, and under it, the lib
and jlib
directories.
For Tomcat, the destination directory is TOMCAT_HOME/common/lib
.
Table 22-8 ADF Runtime Library Files to Copy
Copy These Files: | Notes |
---|---|
From
|
These are the ADF runtime library files. |
From
|
These are the ADF runtime library files. |
From
|
These are the JDeveloper runtime library files. |
From
From
|
These are the Oracle MDS files. |
From
|
These are the Oracle diagnostics files. |
From
|
These are the OJMisc runtime files. |
From
|
This file is for XML support. |
From
|
These are the TopLink library files. |
From
|
These are the XSQL library files. |
From
|
These files are for interMedia Text support. interMedia Text is a feature for storing, retrieving, and manipulating audio, document, image, and video data in an Oracle database. |
From
|
These are the SQLJ runtime library files. |
From
From
|
These are the JDBC runtime library files. |
From
|
These are the Java Cache runtime library files. |
From
|
This file is for Business Components web application image and cascading style sheet support. If you are running Tomcat, copy the If you are running JBoss, copy the |
If you used the wizard to install the ADF runtime library, you should use the wizard to delete the library. On the Installation Options page in the wizard, choose the Delete option.
If you installed the ADF runtime library manually, you can just manually delete the files from your application server.