D60387GC10 Ag
D60387GC10 Ag
D73637
July 2011
Edition 1.0
D60387GC10
Services
Activity Guide
11g: Administer Forms
Oracle Fusion Middleware
Disclaimer
This document contains proprietary information and is protected by copyright and other intellectual property laws. You may copy and
print this document solely for your own use in an Oracle training course. The document may not be modified or altered in any way.
Except where your use constitutes "fair use" under copyright law, you may not use, share, download, upload, copy, print, display,
perform, reproduce, publish, license, post, transmit, or distribute this document in whole or in part without the express authorization
of Oracle.
The information contained in this document is subject to change without notice. If you find any problems in the document, please
report them in writing to: Oracle University, 500 Oracle Parkway, Redwood Shores, California 94065 USA. This document is not
warranted to be error-free.
If this documentation is delivered to the United States Government or anyone using the documentation on behalf of the United
States Government, the following notice is applicable:
Trademark Notice
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective
owners.
Author
Pam Gamer
Table of Contents
Practices for Lesson 1: Fusion Middleware 11g: Administer Forms Services ...........................................1-1
Overview of Practices for Lesson 1 ................................................................................................................1-2
Practices for Lesson 2: Introducing Oracle Fusion Middleware and Oracle Forms Services ...................2-1
Overview of Practices for Lesson 2 ................................................................................................................2-2
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms ......................................3-1
Practices for Lesson 3....................................................................................................................................3-2
Practices for Lesson 2: Introducing Oracle Fusion Middleware and Oracle Forms Services
Chapter 2 - Page 1
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 2: Introducing Oracle Fusion Middleware and Oracle Forms Services
Chapter 2 - Page 2
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 1
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 2
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 3
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Determining the State of the Installation
Examine the Middleware Home directory on your system and determine how much of the
installation is complete. What remains to be done?
a. In Windows Explorer, navigate to C:\Oracle\Middleware.
b. You can see that the wlserver_10.3, as_1, and oracle_common directories are
present, so you know that the WebLogic Server and the base Forms release have
been installed.
c. There is a clone subdirectory under the as_1 Oracle Home directory, so you know
that the middleware patch has been applied.
d. You can see that the Oracle instance (asinst_1 directory) and the domain and
servers (under user_projects) have not yet been created, so you can conclude that
the configuration step has not yet been done.
2. Completing the Installation
b. When the installer appears, click Next to close the Welcome Page.
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 4
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. On the Select Domain page, enter and confirm the password to use for your WebLogic
domain. Use the password weblogic1.
Note: Be extremely careful when entering the password. Ensure that the Caps Lock
key is not on. If you enter the password incorrectly, you may not be able to stop and
restart servers, which impedes your ability to perform later practices.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 5
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
d. On the Specify Security Updates page, deselect the I wish to receive security
updates via My Oracle Support check box and click Next.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 6
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
f. On the Specify Installation Location page, accept the default values by clicking Next.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 7
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
h. Click Next to accept the default values on the next few screens until you reach the
Specify Application OID page.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 8
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
i. On the Specify Application OID page, deselect the Use Application Level Identity
Store check box, and then click Next.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 9
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
l. The process takes several minutes. When all components are successfully configured,
click Next.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 10
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
m. On the summary page, click Save and save the installation configuration to any
directory of your choice, and then click Finish.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 11
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 12
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
b. On the HTML page that appears in your browser, accept all the default values and click
Run form.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 13
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. Depending on its security settings, your browser may display different security
warnings.
1) If your browser displays a warning about running scripts or ActiveX controls, click
in the information bar and select Allow Blocked Content.
3) Another security warning may display a message about restricted content. Click in
the information bar and select Installation Blocked > Install This Add-on for All
Users on This Computer.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 14
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Note: If you are using a standard classroom configuration, with the directories as listed in
the examples in the beginning of the practices for this lesson, you do not have to create the
shortcuts manually. In your lab solutions directory, under Practice1, open the
WLS_Shortcuts folder and copy all the shortcuts in that folder to your desktop. After you
have done that, you do not have to complete the steps below.
Create desktop shortcuts for the following by using the right-mouse button to drag the file
from Windows Explorer to the desktop and selecting Create Shortcut from the context
menu:
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 15
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
In the examples below, substitute your own values for the <Middleware_Home> ,
<Domain_Home>, <Oracle_Instance>, <Oracle_Home>, and <host>.
− <Domain_Home>\bin\startWebLogic.cmd
− <Domain_Home>\bin\stopWebLogic.cmd
After you create the shortcut, right-click the shortcut and select Properties.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 16
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
− <Domain_Home>\bin\startManagedWebLogic.cmd
After you create the shortcut, right-click the shortcut and select Properties.
For example:
− <Domain_Home>\bin\stopManagedWebLogic.cmd
After you create the shortcut, right-click the shortcut and select Properties.
− <Domain_Home>\bin\startManagedWebLogic.cmd
After you create the shortcut, right-click the shortcut and select Properties.
− <Domain_Home>\bin\stopManagedWebLogic.cmd
After creating the shortcut, right-click the shortcut and select Properties.
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 17
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
− <Oracle_Instance>\bin\opmnctl.bat
After you create the shortcut, right-click the shortcut and select Properties.
− <Oracle_Instance>\bin\opmnctl.bat
− <Oracle_Home>\bin\frmbld.exe
Name the shortcut: Forms Builder
− %SystemRoot%\explorer.exe (Windows Explorer)
Practices for Lesson 3: Installing Oracle Fusion Middleware and Oracle Forms
Chapter 3 - Page 18
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 1
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Previous Practices
It is assumed that you finished the practices for the previous lesson, which must be completed
before starting this set of practices so that the Forms components are configured.
The Practice 3 solutions directory contains the desktop shortcuts that you optionally created. If
you did not create them, you can copy them to your desktop now, if desired, and edit the
properties of each to ensure that directories and host names are correct.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 2
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Running the Course Application
b. On the HTML page that appears in your browser, enter the following values and click
Run form:
Fields Values
Form <lab directory>\summit.fmx;
for example:
C:\D60387GC10_labs\labs\summit.fmx
Userid Connect string given by your instructor;
for example:
summit/ORACLE@orcl
Web host localhost
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 3
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 4
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
d. Drag a corner of the form to enlarge it so that you can see all buttons: Customers,
Orders, and Client Utilities.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 5
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
g. Click the Customers button. You should see a message indicating that the Customers
form cannot be read. Repeat with the Orders button to see the same message for the
Orders form.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 6
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 7
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
b. Near the top of the file are four parameters labeled “System parameter:”. This
indicates parameters that cannot be passed on the URL, although they can be
overridden in a named configuration.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 8
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 9
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Using Enterprise Manager for Forms Servlet Configuration
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 10
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
3) Click Login.
4) Select your accessibility preference and click Continue.
On the Web Configuration page, you can see the default configuration and the
three named configurations that you saw in the formsweb.cfg file when you
opened it in a text editor.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 11
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Add a named configuration called [summit] to include the following parameter values,
substituting your values for the italicized components:
Parameters Values
userid <connect string>
width 100%
height 100%
a. Click Create.
b. In the Create Section dialog box, enter a Section Name of summit and click Create.
c. Click Close to close the Confirmation dialog box. You should see the summit named
configuration section, with the lower part of the screen open to add parameters to the
summit section.
d. Set a parameter so that users do not have to pass their database connection
information on the URL or log in to the application.
1) Ensure that the summit named configuration is selected in the upper part of the
screen.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 12
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
2) Scroll to the lower part of the screen, select the userid parameter, and click
Override.
e. Set the size of the Forms applet to automatically adjust to the size of the browser
window.
1) Select the width parameter and click Override.
2) Set the value to 100%.
3) Do the same for the height parameter.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 13
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
f. Override the form parameter and set it to the complete path of the Summit form, such
as C:\D60387GC10_labs\labs\summit.fmx.
Note: You need to specify the complete path because you have not yet defined an
environment variable to tell Forms Services where to look for forms. You do that in the
practices for the lesson titled “Configuring the Middle Tier: Environment, UI, and
Deployment.”
g. Click Apply, and then click Close to acknowledge the Confirmation dialog box.
h. Set the page title to Summit Office Supply Order System.
1) From the Show drop-down list, select html.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 14
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 15
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
3) The form applet consumes all available space in the browser, as specified by the
width and height parameters in the [summit] configuration. You can confirm
this by resizing the browser window; notice that the applet size changes
accordingly.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 16
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Defining a Named Configuration to Prestart Runtime Processes
b. In the Create Like dialog box, select summit as the Section to Duplicate, enter
summit_prestart as the New Section Name, and click Create.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 17
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. Select the summit_prestart section, select all from the Show drop-down list, and click
Add.
e. In a similar fashion, add the remaining parameters shown in the table above, and then
click Apply.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 18
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. When the Start WLS_FORMS window displays the message “Server started in
RUNNING mode,” you can minimize the command window, but do not close it.
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 19
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
____________________________________________________________________
____________________________________________________________________
e. At least twenty minutes after the server restarted, check the Task Manager again. (If
twenty minutes have not yet passed, you can finish this practice after the lesson titled
“Configuring the Middle Tier: Environment, UI, and Deployment.”) What do you
observe?
____________________________________________________________________
____________________________________________________________________
____________________________________________________________________
____________________________________________________________________
The prestarted processes no longer exist, except for any that are being used by
running applications.
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 20
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Chapter 4 - Page 21
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Chapter 4 - Page 22
Practices for Lesson 4: Configuring the Middle Tier: The Forms Servlet
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Oracle University and Koenig Solutions Private Limited use only
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 1
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Previous Practices
It is assumed that you successfully completed all previous practices.
The solution directory for Practice 4 contains the formsweb.cfg file with the configuration that
was done in that practice. If you want to use this file, copy it to
<formsapp directory>\config.
There may be additional configuration steps needed, such as environment modifications. Merely
copying the files may not be sufficient.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 2
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Open the default environment file and examine the definitions it contains.
a. In Windows Explorer, navigate to
<domain_home>\config\fmwconfig\servers\WLS_FORMS\applications\
formsapp_11.1.1\config and open default.env in either Notepad or WordPad.
b. Notice the following environment variables that are defined in the first part of the file:
1) ORACLE_HOME: Defined as the as_1 directory under the Middleware Home. You
will probably never need to change this setting.
2) ORACLE_INSTANCE: Defined as the asinst_1 directory under the Middleware
Home. You will probably never need to change this setting.
3) TNS_ADMIN: Points to the directory where the tnsnames.ora file is located to
specify SQL*Net databases to which Forms applications can connect. If you have
a central tnsnames.ora file where you want to store all database information,
you could modify this environment variable to point to the directory where it is
stored.
Note: If you are using Forms Builder, it does not recognize environment variables
that are set in the Forms Servlet’s environment file, which are for run time only. To
enable database connections from Forms Builder, you must set TNS_ADMIN for
the operating system environment, such as in the Windows registry.
c. FORMS_PATH defines the search path for forms and related executables. Can you see
why Forms Services cannot locate the forms in the Summit application unless a
complete path is given?
_____________________________________________________________________
_____________________________________________________________________
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 3
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 4
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Using Enterprise Manager for Environment Configuration
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 5
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
2) The browser displays the contents of the default.env file. You can resize the
Value column to be able to see more of the values, or you can click in a field and
scroll to the end.
Add an application-specific environment file called summit.env to include the search path
to the Summit application and a pointer to the database tnsnames.ora file.
a. Click Duplicate File.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 6
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
b. In the Duplicate File dialog box, enter summit.env in the Name field and click
Duplicate.
e. Set the search path for forms to the lab directory where the Summit application is
located.
1) Select the FORMS_PATH environment variable and change the value to the path to
your Labs directory.
2) Click Apply.
f. The TNS_ADMIN environment variable is, by default, set to
<ORACLE_INSTANCE>\config, so in the practices for the lesson titled “Installing
Oracle Fusion Middleware and Oracle Forms,” you copied the database
tnsnames.ora file to that location so that the Summit application would initially run.
However, it is usually better to have only one tnsnames.ora file so that all
modifications can be made in one place. Set the Summit application to use the
database’s tnsnames.ora file.
1) Set TNS_ADMIN to <DATABASE_HOME>\NETWORK\ADMIN, which is the location of
the database’s tnsnames.ora file, such as
C:\app\Administrator\product\11.2.0\dbhome_1\NETWORK\ADMIN.
2) Click Apply.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 7
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 8
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
4)
Click Apply.
Chapter 5 - Page 9
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Oracle University and Koenig Solutions Private Limited use only
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 10
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
1) Click Enter Query (or select Query > Enter from the menu).
2) Enter 106 in the ID field and click Execute Query (or select Query > Execute
from the menu).
4) A new empty record appears to enable you to enter a new record. Click Previous
Record (or Record > Previous from the menu) to return to customer 106.
f. Using the query-where functionality, query for customers whose ID is greater than 106.
Note: It is not necessary to use the query-where functionality here; in this case, you
could just enter “>106” in the ID field. However, the following illustrates that the
query-where functionality is not currently working.
1) Click Enter Query (or select Query > Enter from the menu).
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 11
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
2) Enter a colon (:) in the ID field and click Execute Query (or select Query >
Execute from the menu). The status line displays an error because the
query-where functionality is not enabled.
4) Exit the Customer form by clicking Exit Form (or select Action > Exit from
the menu).
g. Click Client Utilities.
h. The Client Utilities form opens, but displays an error warning of an unhandled
exception. Click OK to dismiss the message.
Note: Any attempt to use the client utilities results in additional error messages. You
correct these errors by the configuration steps you perform in the practices for the
lesson titled “Configuring the Client Tier”.
i. Click Exit to dismiss the Client Utilities form. (The Exit button is in the lower-right
corner of the form; you may need to scroll down to see it.)
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 12
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 13
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Enabling the Query-Where Functionality
d. Click Enter Query (or select Query > Enter from the menu).
e. Enter a colon (:) in the ID field and click Execute Query (or select Query >
Execute from the menu).
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 14
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
f. In the Query/Where dialog box, enter the following query criteria and click OK:
customer_id > 106
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 15
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
i. Orders for customer 108 are displayed. You can click Next Record to tab through
them if you like.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 16
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Examining the Default Forms Registry
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 17
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
a. From the Notepad or WordPad menu, select File > Save As.
b. Save the file under a different name, such as Registry.dat.orig.
c. Close the file.
3. Using Enterprise Manager to Change Fonts
The application developer has informed you that the Customers form was designed to show
the customer’s last name in the Monotype Corsiva font as shown below, but it does not
appear that way at run time.
a. In Enterprise Manager, open the Forms Registry file by selecting Font and Icon
Mapping from the forms menu.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 18
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Users have requested some sort of visual indicator to show which fields are required and
which fields have LOVs attached. The application developer has asked you if there is some
way to do this without modifying all of the forms individually. Implement this functionality.
a. In the Font and Icon Mapping window of Enterprise Manager, set the following values:
Name Value
app.ui.lov.Buttons true
app.ui.requiredFieldVA true
app.ui.requiredFieldVABGColor 153,102,255
(These are RGB values separated
by commas. You can use any color
you like as long as it is light enough
for the text of the field to be visible.)
b. Click Apply.
To ensure that Forms run time picks up these changes, perform the following steps:
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 19
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 20
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
4) Click Close and OK to dismiss the Java Cache Viewer and the Java Control Panel.
d. Shut down and restart the WLS_Forms managed server.
1) If you completed the optional Task 2 of Practice 3-2, double-click the desktop icon
named Stop WLS_FORMS.
If you did not create this shortcut, then select Start > Oracle Classic Instance –
asinst_1 > Forms Services > Stop Weblogic Server WLS_FORMS.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 21
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 22
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Copying the Binaries to the Target Platform
Copy the binary files to the WebLogic Server machine. Because you are using the same
machine for development and testing, simulate this step by copying the binary files to a
different directory, such as formsapp. (You need to first create this directory.)
a. Open Windows Explorer (you can use the Windows + E keyboard shortcut or, if you
created shortcuts in Practice 3, use the Windows Explorer shortcut.)
b. Ensure that you see a two-panel view; if not, click Folders.
c. In the left panel, select the Local Disk (E:) folder, or another local drive if you do not
have an E drive on your computer.
d. Right-click in the right panel and select New > Folder.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 23
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 24
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 25
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Note: If the file has not been created, open customers.err in WordPad or
Notepad to see why. The .err file is created as a log of compilation actions,
whether or not there are errors.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 26
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
e. You could repeat steps b and c above for each form. However, if there are many forms,
this could become very time-consuming. Instead, you could choose to create a
summit.bat script file, including the following commands: (This batch file is included
in your lab files directory.)
@echo off
if "%1" == "" goto ERROR
REM Forms
for /R %%F in (*.fmb) do start /w frmcmp.exe userid=%1 batch=y
module=%%F compile_all=yes
Note: This script compiles all form, menu, and library modules in a single directory.
You run the batch file by issuing the command summit followed by the database
connect string.
f. Compile the remaining forms, by running the batch file as follows (substitute your
connect string if different):
summit summit/ORACLE@orcl
Note: If you run the script, you see an Oracle Forms Compiler window flash
momentarily for each module that is being compiled.
1) Copy summit.bat from your Files directory to your \formsapp directory.
2) Open a command window and navigate to the \formsapp directory.
3) Enter the command above. The compiler window flashes once for each form that
is generated.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 27
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Configure the environment, Forms Servlet, and registry on the middle tier.
a. Set the environment variable to point to the location of your executables.
1) Open and log in to Enterprise Manager.
2) Navigate to the summit.env file.
3) Set FORMS_PATH to point to the new file location, such as e:\formsapp, deleting
the existing path and replacing it with the new location.
4) Click Apply.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 28
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
b. Do not do this step. Although the following steps are not necessary because you are
deploying to the same machine, if you were deploying to a different computer, you
would need to:
1) Copy and paste the [summit] named configuration from your local
formsweb.cfg file to the one on the target platform, or replace the target
formsweb.cfg file with your local one.
2) Copy the local summit.env file to your target platform.
3) Copy the local Registry.dat file to your target platform, or make similar
modifications as you did in your local file.
Run the Summit application on the deployment platform to ensure that it functions and
looks the same as on the development platform.
a. First, so that you are sure that the files being accessed are from the “deployment
platform” (\formsapp), rename the original directory where the forms are located
(your lab directory) to \summit_labs. This becomes the new value for your lab
directory in future references to it.
Note: This step ensures that the Summit application cannot be accessed from the
\labs path.
b. In a browser, enter the Summit application URL:
http://<host>:8888/forms/frmservlet?config=summit, where <host> is the machine
name.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 29
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
The application should function and appear just as it did when run on the “local
platform,” except that when you navigate to the Orders form, the status line displays a
message indicating that an image file cannot be located.
Practices for Lesson 5: Configuring the Middle Tier: Environment, UI, and Deployment
Chapter 5 - Page 30
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Previous Practices
It is assumed that you successfully completed all previous practices.
The solution directory for Practice 5 contains configuration files that were modified by
completing that practice. If you want to use these files, copy them as follows:
File Copy to:
formsweb.cfg, <formsapp directory>\config
summit.env
Registry.dat <formsapp directory>\config\forms\registry\
oracle\forms\registry
There may be additional configuration steps needed, such as environment modifications. Merely
copying the files may not be sufficient.
Tasks
1. Deploying Image Files
Deploy the .jpg image files to the middle tier so that they can be accessed in a form by
the READ_IMAGE_FILE command with the file type argument of JPEG.
a. Examine the FORMS_PATH setting for the Summit application.
1) In Enterprise Manager, navigate to the Forms environment file.
2) Select summit.env from the Show drop-down list.
3) Take note of the setting for FORMS_PATH, which should include the directory
where your .fmx files are deployed.
b. Deploy the .jpg images.
1) In Windows Explorer, select all of the.jpg images in your lab files directory
(except for mysplash.jpg and summit_bg.jpg) and select Copy from the
context menu.
2) Select the directory where your forms are deployed and select Paste from the
context menu.
2. Testing Image Deployment
c. On the Customers form, click Orders to invoke the Orders form. Ensure that the
product image appears.
e. Exit the forms and close the browser when you have finished testing.
Deploy the summit_bg.jpg file. Note that you are using a Java Plug-in whose version is
greater than 1.6 update 19.
a. Copy the summit_bg.jpg image from your lab files directory to the
<ORACLE_HOME>\forms\java directory.
b. Using Enterprise Manager to edit the Forms Servlet configuration file, set the
following parameter values for the Summit application by overriding the default values:
Parameter Value
imageBase DocumentBase
background /forms/java/summit_bg.jpg
2. Testing Applet Image Deployment
Test the application to ensure that the splash screen appears as the form loads.
a. If there is already a browser open in which a Forms session has been running,
completely close the browser.
b. Run the Summit application in a browser.
c. Ensure that the background image appears.
d. Exit the form and close the browser when you have finished testing.
Deploy the list.gif and check.gif files (in your lab files directory) in a JAR file called
myicons.jar.
a. Open a command window and navigate to your lab files directory.
Issue the following commands:
set PATH=<ORACLE_HOME>\jdk\bin;%PATH% (substitute your value for
<ORACLE_HOME>)
jar –cvf myicons.jar *.gif
exit
c. In Enterprise Manager:
1) In the Forms Servlet configuration for the summit named configuration:
a) Set the archive parameter to include the myicons.jar file.
Test that the icons now appear on buttons in the Summit application.
Note: If you are using JPI version 6 update 19 or greater, you see a security warning box
asking if you want to block potentially unsafe components from being run. For now, click No
so that the components (from the myicons.jar file) are allowed. You work around this
issue in the practices for the lesson titled “Configuring the Client Tier.”
In this case, you do not deploy to the client the images that are used by the
READ_IMAGE_FILE command. Why not?
_______________________________________________________________________
_______________________________________________________________________
_______________________________________________________________________
_______________________________________________________________________
a. One reason is that the developer would have to change the READ_IMAGE_FILE
command to use a URL file type.
b. A second reason is that the images do not have the same file extension as the icons.
Tasks
b. In Enterprise Manager, set the archive parameter of the Forms Servlet configuration
to include the colorpicker.jar and rolloverbutton.jar files for the summit
named configuration. Add these to the end of the existing value, separated by
commas.
Test the application. The Color button on the Customers form should invoke the color
picker, and the toolbar buttons on the Orders form should be rounded, with a different
rollover image on the Exit button.
a. Run the Summit application in a browser.
b. Answer No to the security warning asking if you want to block potentially unsafe
components.
c. Ensure that the button in the Customer form functions to call the Java code that
d. Ensure that the Orders form has toolbar buttons with rounded edges and that the
appearance of the Exit button changes when the mouse rolls over the button.
e. Exit the form and close the browser when you have finished testing.
Previous Practices
It is assumed that you successfully completed all previous practices.
The solution directory for Practice 6 contains configuration files that were modified by
completing that practice. If you want to use these files, copy them as follows:
File Copy to:
formsweb.cfg <formsapp directory>\config
Registry.dat <formsapp directory>\config\forms\registry\
oracle\forms\registry
colorpicker.jar, <Oracle_Home>\forms\java
rolloverbutton.jar,
summit_bg.jpg
There may be additional configuration steps needed, such as environment modifications. Merely
copying the files may not be sufficient.
Use Enterprise Manager to examine the default JPI settings in the Forms Servlet
configuration.
a. Open Enterprise Manager and navigate to the Forms Web Configuration page.
b. Select the summit configuration.
c. Select plugin from the Show drop-down list.
d. Scroll to the bottom of the section to see the parameters beginning with “jpi-”.
e. Optional: Check the location of the jpi_download_page parameter by entering its
value as the URL in a browser. You should see the page where users of browsers
other than Internet Explorer can download the plug-in.
f. Optional: Check the location of the jpi_codebase parameter by entering its value as
the URL in a browser. You should be prompted to open or save the file. Click Cancel.
Users of the Summit application are complaining that when they accidentally navigate away
from the running application and click the Back button to return to it, the application restarts
and they lose any data that they may have entered. Change the configuration to fix this
problem.
a. Confirm the default behavior by running the Summit application and testing that the
application restarts when navigating away from the running application and then
clicking Back.
1) Run the Summit application, answer No to the security warning, and navigate to
the Customers form.
2) Change the customer’s last name, but do not save the change.
3) On the same browser page, enter another URL, such as http://www.oracle.com,
to navigate away from the Summit application.
4) When the new page appears, click the browser’s Back button. You should see that
the application restarts and the data entry of the changed customer’s last name is
lost.
5) Reload the page (View > Refresh). The application reloads, as you would expect.
Your changed data is not available. This is in contrast to what happens in step e
below.
b. On the Forms Web Configuration page of Enterprise Manager, select the summit
configuration.
c. Select advanced from the Show drop-down list.
d. Override the value for legacy_lifecycle, set it to true, and click Apply.
e. Test the change by repeating step a. You should see that the application resumes from
where it left off and that the new customer’s last name is preserved, ready to be saved
to the database.
Note: If you do not initially see the existing application, reload the page (View >
Refresh); it should then appear as it was prior to navigating to a different page.
f. Exit the form without saving changes and close the browser.
Note: This line can be entered automatically by opening the Java Control Panel,
clicking the Advanced tab, expanding the Java Console node, and selecting the
“Show console” option.
2. Changing the Trace Level
Implement two ways to change the trace level of the Java Console. Use the Java Console
at run time to change to the most verbose trace level. After testing that, use the properties
file to change to trace level 2.
a. Change the trace level to the most verbose level as the Summit application starts.
1) Run the Summit application in a browser. The Java Console should appear as the
application starts.
2) When the Java Console appears, use the alphanumeric keyboard to enter “5” into
the console. The console displays a message indicating that the trace level is now
5, and then messages of all trace levels are displayed.
2) Add the following lines, and then save and close the file:
deployment.trace=true
deployment.trace.level=basic|net
Assumptions
The application developer has already integrated the WebUtil functionality into the Summit
application, accessed with the Client Utilities button. The application uses the file transfer
functionality, database transfer functionality, and OLE automation. The database administrator
has already configured the database for database transfers.
Tasks
1. Configuring the WebUtil Basic Functionality
Configure the Summit application on the middle tier to enable it to use the basic
functionality of WebUtil.
a. Ensure that a webutil virtual directory has been defined:
1) In Notepad or WordPad, open
<domain-home>\deploymentplans\formsapp\11.1.1\plan.xml.
2) Search for the word “webutil” – you should see that the webutil virtual path has
been defined. This was done automatically during installation.
6) Open Enterprise Manager in a browser and ensure that the new entries are in the
[summit] configuration.
5) Click Apply.
2. Configuring the WebUtil File Transfer and Database Functionality
Configure the middle tier for file transfer and database transfer functionality.
a. In summit.env, ensure that the PATH variable includes
<Oracle_Home>\jdk\jre\bin\client. If you make any changes, click Apply, but
you should not need to make changes because, by default, this setting is made during
installation.
Enable WebUtil to use the OLE functionality. The jacob files have already been
downloaded and are located in your lab files directory, which also contains another file,
ffisamp.dll, that is used by the application.
Note: The OLE functionality in the Summit application works with Microsoft Word, so is
possible only on computers with Word installed. However, because the OLE functionality is
coded into the application, the jacob files must be deployed regardless of whether OLE is
used.
a. Copy jacob.jar from your lab files directory to your <ORACLE_Home>\forms\java
directory.
c. Ensure that the size of the jacob.dll file matches the webutil.cfg entry.
1) In Windows Explorer, right-click the jacob.dll file and select Properties.
2) Make note of the file size and dismiss the Properties dialog box.
3) In the webutil.cfg file, ensure that the file size in the install.syslib.0.7.1
entry is the same as the actual size of jacob.dll. If not, change it to read as
follows:
install.syslib.0.7.1=jacob.dll|106496|1.10|true
4) Save and close the webutil.cfg file.
d. Sign the jacob.jar file.
1) Edit the JAR-signing batch file to specify key, passwords, keystore directory, and
number of days signature is valid. Use the following examples:
SET KEYSTORE_PASSWORD=webutilpasswd
(If the keystore already exists, you must use its password; otherwise, this becomes
the password for a new keystore.)
SET JAR_KEY=webutil2
SET JAR_KEY_PASSWORD=webutil2
SET VALIDDAYS=360
a) Open the <Oracle_Instance>\bin\sign_webutil.bat file in WordPad.
b) Make the modifications listed above.
set CLASSPATH=%ORACLE_HOME%\jdk\bin
iv) In the command window, set PATH to include
<ORACLE_Home>\forms\java\ and
<ORACLE_Home>\forms\webutil, as in the following example:
set
sign_webutil %ORACLE_HOME%\forms\java\jacob.jar
vi) You can leave the command window open for a later task.
4. Compiling the WebUtil Library
The webutil.pll library file that was created during installation has not been compiled on
this platform, so you may still receive errors if you try to use the Webutil functionality.
Compile this library to avoid these errors.
a. Open a command window and navigate to <ORACLE_HOME>\forms.
b. Set the TNS_ADMIN environment variable to the location of your database
tnsnames.ora file with a command such as:
Set TNS_ADMIN=C:\app\Administrator\product\11.2.0\dbhome_1\
NETWORK\ADMIN
c. Enter the frmcmp command.
To import the certificate to the browser’s list of trusted certificates, select the check box
labeled “Always trust content from this publisher” and then click Run.
g. Click the Open File button (the one with the ellipsis icon).
h. In the dialog box, navigate to any .gif image on the client computer, such as
i. The path to the desired image is populated. Click Read Image to read the image from
the client computer into the form. The image displays on the form in the area labeled
“Image:”.
j. You can continue to experiment with the Client Utilities form as desired. When finished,
click Exit, and then click OK in the Session API Test dialog box.
Note: The OLE functionality in this particular form integrates with Microsoft Word, so it
works only on client computers where Microsoft Word is installed.
Tasks
1. Signing the JAR Files
Run the batch file to sign the icon and JavaBean JAR files.
a. If you closed the command window that you opened earlier, then do the following:
1) Open a command prompt window and navigate to the <Oracle_Instance>\bin
directory.
2) In the command window, set ORACLE_HOME, as in the following example:
SET ORACLE_HOME=C:\Oracle\Middleware\as_1
3) In the command window, set the CLASSPATH to include
<ORACLE_Home>\jdk\bin, as in the following example:
set CLASSPATH=%ORACLE_HOME%\jdk\bin
4) In the command window, set PATH to include <ORACLE_Home>\forms\java\ and
<ORACLE_Home>\forms\webutil, as in the following example:
set PATH=%ORACLE_HOME%\forms\java;%ORACLE_HOME%\forms\webutil;%PATH%
b. Run the JAR-signing batch file to sign myicons.jar:
sign_webutil %ORACLE_HOME%\forms\java\myicons.jar
Note: If you have run this batch file previously, as you did when you signed
jacob.jar, then you will receive error messages when the batch file attempts to
generate the key pair and self-signing certificate because they have already been
generated. You can ignore these errors.
sign_webutil %ORACLE_HOME%\forms\java\colorpicker.jar
d. Run the JAR-signing batch file to sign rolloverbutton.jar:
sign_webutil %ORACLE_HOME%\forms\java\rolloverbutton.jar
e. Close the command window by entering exit.
2. Resetting the Background Parameter
Test that the icons now appear on buttons in the Summit application and that Java code
functions correctly.
a. Run the Summit application. It should run without security warning about the blocked
content.
b. Ensure that the button in the Customer form functions to call the Java code that
invokes a color picker.
c. Navigate to the Orders form. Images should still appear on the buttons
e. Exit the form and close the browser when you have finished testing.
Previous Practices
Tasks
1. Deploying and Generating the Translated Modules
Deploy and generate the forms to the middle tier in directories named myapp/English
and myapp/German, renaming the files so that they have the same name.
a. In Windows Explorer create a middle-tier directory called myapp, with subdirectories
English and German.
d. In a command window, use the frmcmp command to generate the forms. (See
Practice 5-5, task 2.)
Using Enterprise Manager, create and configure environment files to locate each form.
a. Make two copies of summit.env named English.env and German.env.
b. Modify each to set the FORMS_PATH to include the location of the corresponding
Customers_List form:
1) In the English.env file:
FORMS_PATH=C:\myapp\English
(use the complete path to the \English directory)
Modify the formsweb.cfg file so that the German form is displayed by default, and also
create a language-specific section for English. Set the appropriate environment file for each
section.
a. Add the following named configuration to the formsweb.cfg file (this is the default
that displays if no browser language preference matches any of the sub-
configurations):
[customers]
envFile=German.env
form=customer_list.fmx
userid=<your connection information>
___________________________________________________________________
___________________________________________________________________
___________________________________________________________________
1) When you run the Forms Servlet URL with ?config=customers appended to
the URL, the German form should run if the language preference is set to any
language other than English[en], because that is what is specified in the
default [customers] configuration.
2) The English form should run only if the language preference is set to American
English (English (United States) [en-US]).
e. Set browser preferences to English (United States) [en-US]. If there are other
languages, ensure that the top one is English (United States) [en-US].
f. Run the Forms Servlet with config=customers. The English form appears.
Note: When you have multiple languages in the browser preference, Forms first looks
for a configuration section for the first (top) language. If not found, it looks for a
configuration section for the second language, and so on until a matching configuration
section is found. If there is no matching configuration for any of the specified
languages, then the default configuration for the application (in this case,
[customers]) is used.
g. Exit the form and close the browser.
Tasks
1. Modifying the Application to Restrict URL Parameters
Modify the summit configuration so that users cannot pass the userid parameter on the
URL.
a. In Oracle Enterprise Manager, navigate to the Forms Web Configuration page.
b. Select the [summit] configuration.
c. Select advanced from the Show drop-down list.
d. Override the restrictedURLparams parameter.
e. Add ,userid to the end of the parameter and click Apply.
Test that the userid parameter cannot be changed by the application user.
a. In a browser, enter the URL for the Summit application, followed by a userid
parameter, such as: &userid=xyz/pwd@abc.com
b. You receive a warning that you cannot specify the userid parameter on the URL.
Tasks
1. Creating a Certificate
b. On the ohs1 home page, select Security > Wallets. From the Oracle HTTP Server
menu
e. A confirmation message is displayed and the new wallet appears in the list of wallets.
Use the existing SSL listen port for OHS and set it to use the wallet that you just created.
a. From the Oracle HTTP Server menu, select Administration > Virtual Hosts.
c. On the SSL Configuration page select summit_wallet from the Server Wallet Name
drop-down list and click OK.
f. When the Confirmation dialog box displays a success message, click Close. Because
you are using the existing SSL listen port, you do not have to separately enable the
Web Cache port to accept HTTPS communications from OHS, because it is configured
this way by default.
Test that you can use SSL to run the Summit application.
a. Open a browser and enter the SSL URL for the Summit application:
https://localhost:8890/forms/frmservlet?config=summit
b. Because you are using a self-signed certificate, you receive a warning that the web
site’s certificate was not issued by a trusted authority. Ignore this warning by clicking
Continue to this website (not recommended).
d. As the application starts, you may get another security warning that the application’s
digital certificate cannot be verified. Select the Always trust content from this
publisher check box and click Run.
e. The Summit application should now run as usual.
Note: If buttons do not display their images, try stopping WLS_FORMS and then the
Admin Server, and then restarting the Admin Server and WLS_FORMS. Then run
Summit in SSL mode again; the icons should appear.
Chapter 9 - Page 10
Practices for Lesson 9: Implementing Security for Forms Applications
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Oracle University and Koenig Solutions Private Limited use only
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 1
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 2
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Creating a Reports Server
The Orders form of the Summit application uses RUN_REPORT_OBJECT to run an invoice
report on a reports server named RptSvr_summit. If you are on a network, the reports
server name must be unique on the network.
Use Forms Builder to modify the name of the reports server used by the form so that its
name is unique. Demonstrate that this reports server does not yet exist, and then create
and start it.
a. Modify the registry TNS_ADMIN entry so that Forms Builder can connect to the
database.
1) Run the registry editor (Start > Run > regedit).
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 3
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
2) Modify the data value of the TNS_ADMIN string in the Forms home key
HKEY_LOCAL_MACHINE > SOFTWARE > ORACLE > <Forms key, such as
KEY_OH650614976>.
Change the data value to the location of the tnsnames.ora file for the database,
such as
C:\app\Administrator\product\11.2.0\dbhome_1\NETWORK\ADMIN.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 4
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 5
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
7) Select Program > Compile Module from the Forms menu and log in with your
database connection information when prompted.
8) Select File > Exit from the menu to exit Forms Builder, choosing again to save the
form if prompted.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 6
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. Demonstrate that this server does not yet exist and then create and start it.
1) Run the Summit application, navigate to the Orders form, and click Invoice. What
happens?
_________________________________________________________________
_________________________________________________________________
_________________________________________________________________
________________________________________________________________
________________________________________________________________
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 7
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
The reports server that is being called from Forms, the one that you specified with
a unique name, does not appear.
______________________________________________________________
_
______________________________________________________________
_
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 8
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
The reports server that is being called from Forms (with the unique name that
you specified earlier) does not appear.
for example:
opmnctl createcomponent -adminUsername weblogic -
adminHost myhost -adminPort 7001 -oracleHome
c:\oracle\middleware\as_1 -oracleInstance
c:\oracle\middleware\asinst_1 -instanceName asinst_1 -
-componentName RptSvr_summitPam -componentType
ReportsServerComponent
Note: Be sure to spell the reports server name exactly the same as the one that
you specified in Forms Builder in step (b)(5)(b) above. A common error is to start
the new reports server with a name beginning with "RptSrv", while it should begin
with "RptSvr".
b) Enter the password when prompted: weblogic1
Note: Characters of the password do not appear when entered.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 9
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
f) In Enterprise Manager, refresh the Farm home page. The new reports server
appears and is up.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 10
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
d. Test running the Invoice report from Forms again. What happens now?
___________________________________________________________________
___________________________________________________________________
Determine the cause of the generic error and rectify it by specifying the database
information for the reports server.
a. The related reports error is not displayed by the form. Examine the log for this reports
server to determine the reason for this error.
1) In Notepad or WordPad, open the rwEng-0_diagnostic.log file from the
<ORACLE_INSTANCE>\diagnostics\logs\ReportsServerComponent\
<Reports Server Name> directory.
2) Note the reports error is REP-0501: The specified database cannot be
connected, followed by the database error ORA-12154: TNS:could not
resolve the connect identifier specified.
This indicates that the Reports environment is not correctly setting the TNS
information so that the database alias in the connect string passed by Forms can
be recognized.
b. (optional) Another way to look at the log file is by using Enterprise Manager:
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 11
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
1) From the Farm Home page, click the link for the reports server that ran the report.
3) On the Finished Jobs page, select Failed Jobs from the Show drop-down list.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 12
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
4) The Failed Jobs page displays all of the failed jobs with associated errors.
opmnctl stopall
opmnctl startall
6) Test running the report from Forms again. You should again receive an FRM-
41214 error.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 13
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Instead of looking at the log, this time use the browser URL with the showjobs command
to determine the cause of the generic error and rectify it by setting the search path for the
reports server.
a. Another way to determine the reason for the error is to use showjobs:
1) Enter the following URL:
http://localhost:8888/reports/rwservlet/showjobs?server=<Reports Server
Name>
3) The Error page displays the specific error. Click OK to return to the Reports Server
Queue Status page.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 14
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
3) On the Finished Jobs page, select Failed Jobs from the Show drop-down list.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 15
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
4) The Failed Jobs page displays all of the failed jobs with associated errors.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 16
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
3) Uncomment the line that sets a value for the sourceDir property and set it to the
c:\formsapp directory. The line should read as follows:
<property name="sourceDir" value="c:\formsapp"/>
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 17
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Examining the Default JavaScript Configuration
By default, Forms is set up to enable JavaScript. Confirm this by examining the JavaScript-
related configuration files.
a. In Oracle Enterprise Manager, navigate to the Forms Web Configuration section.
b. Select the default configuration and select advanced from the Show drop-down list.
c. The three JavaScript Forms Servlet parameters and their default values are;
1) applet_name, which is blank
2) enableJavascriptEvent, which is true
3) JavaScriptBlocksHeartBeat, which is false
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 18
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
The file summitjpi.htm contains the JavaScript calls needed for the JavaScript that is
integrated into the Summit form. Set the Summit application to use this HTML file. The
actual JavaScript file is summit_jsfile.js. Both of these files are in your lab files
directory.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 19
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 20
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 21
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 22
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
i. The developer of the Summit application has told you that the JavaScript that is used in
the form is dependent on an input text field in the HTML to appear above the form, so
that users can enter their names. This field should be called field1.
The developer did not hard-code this field in the HTML form, so override the
HTMLbeforeForm parameter to set it to: Please enter your name: <input
name="field1" type="text" id="field1"><p>
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 23
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
3. Disabling JavaScript
There are some applications where the developer does not want JavaScript to be enabled.
To test the ability to disable JavaScript integration, disable it for the Summit application and
run it again.
a. In the Forms Web Configuration page in Oracle Enterprise Manager, override the
enableJavascriptEvent parameter for the [summit_js] configuration, setting it
to false.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 24
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
c. Run the Summit application again with config=summit_js and enter your name as
before. When the form appears, your name is no longer retrieved into the form and you
receive an error indicating that JavaScript events have been disabled.
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Chapter 10 - Page 25
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Chapter 10 - Page 26
Practices for Lesson 10: Integrating Forms Applications with Other Technologies
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
Oracle University and Koenig Solutions Private Limited use only
THESE eKIT MATERIALS ARE FOR YOUR USE IN THIS CLASSROOM ONLY. COPYING eKIT MATERIALS FROM THIS COMPUTER IS STRICTLY PROHIBITED
Tasks
1. Deploying the JAR file
You can deploy the JAR file to any directory on the middle tier, because you will define a
search path for it when creating JVM controller parameters. Deploy the JAR file to the same
directory as your application.
a. In Windows Explorer, navigate to your lab files directory and copy the summit.jar
file.
b. Navigate to your application directory (for example, c:\formsapp) and paste the
summit.jar file.
2. Configuring Start-up Parameters for a JVM Controller
a. In Enterprise Manager, navigate to the Forms Home page and then select JVM
Configuration from the Forms menu.
d. Select the summitJVM section and in the lower panel click Add to add a parameter.
e. In the Add dialog box, enter the parameter name and value. Use the following values
and create all parameters one at a time:
Parameter Value
jvmoptions -Xms256m -Xmx512m
classpath C:\formsapp\summit.jar
maxsessions 2
logdir C:\formsapp\log
Specify that the Summit application should use the summitJVM controller when invoking
Java code.
a. In Enterprise Manager, select Web Configuration from the Forms menu.
b. On the Web Configuration page, select the summit named configuration and then
select advanced from the Show drop-down list.
c. Click Add.
d. In the Add dialog box, enter the name jvmcontroller and the value summitJVM, and
then click Create.
e. Select the otherparams parameter and click Override.
The Orders form in the Summit application has a Check Order Total button next to the order
total. This button invokes code that was created by using the Java importer to generate a
PL/SQL wrapper for the summit.class Java class that is located in summit.jar. This
code adds up all of the line totals for an order and displays the sum as a message so that
the user can check it against the order total that is displayed on the form.
a. Invoke the Summit application in a browser.
b. Click Orders.
c. Click the Check Order Total button.
d. Because you are using the default value of allowing autostart of the summitJVM
controller, it starts automatically. You can see a command window opening with the
process ID of the controller.
Additionally, if you look in Task Manager you can see the dejvm process.
Navigate to the JVM Controllers page and monitor the use of the summitJVM controller as
you start multiple sessions of the Summit application and invoke the Java code.
Note: To refresh the information on a page, you can click the Refresh icon in the upper
right corner of the page next to the date and time.
.
a. In Enterprise Manager select JVM Controllers from the Forms menu.
b. On the JVM Controllers page, expand the summitJVM controller entry to display
information about the controller. Click the eyeglass icon under the Logfile heading to
see the log.
d. Start two additional sessions without closing the first one, invoking the Java code and
then looking at the JVM Controllers page, the log, and the Windows Task Manager
each time (you will need to refresh the JVM Controller page each time by clicking the
Refresh icon.) What do you observe after invoking the Java code in the third
concurrent session?
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
1) The JVM Controllers page in Enterprise Manager shows that there are now three
sessions and two JVMs.
e. Use Enterprise Manager to shut down the summitJVM controller by clicking Stop with
summitJVM selected in the JVM Controllers page. Confirm that you want to stop the
controller, although there are sessions using it.
f. Return to one of the Summit sessions and click Check Order Total to invoke the Java
code again. What happens and why?
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
A new instance of the summitJVM controller starts and the Java code in the form
executes successfully.
h. Leave all sessions running for the next practice.
Because you shut down a JVM controller that was being used by active sessions, some
sessions are no longer able to execute Java code. Review the log for summitJVM to
determine which Forms sessions have a JVM assigned that no longer exists.
a. On the JVM Controllers page of Enterprise Manager, click the eyeglasses icon
under the Logfile heading to see the log for the summitJVM controller.
b. Make note of the process IDs of the Forms sessions that existed prior to shutting
down the summitJVM controller.
Shut down the user sessions that have the non-existent JVM controller assigned to them.
a. From the Forms menu, select User Sessions.
b. On the User Sessions page, Ctrl + Click to multiselect the invalid user sessions, and
then click Stop.
c. In the Confirmation dialog box, click Yes to confirm that you want to kill the selected
sessions.
d. Click Refresh to refresh the User Sessions page. You should now see only the valid
session.
Note: Of course, it is undesirable to terminate user sessions in this way because any
unsaved information is lost. This should be done only if absolutely necessary.
3. Disallowing New Connections
Change the system so that new users cannot connect, and then test that the setting is
working.
a. In Enterprise Manager, select Web Configuration from the Forms menu.
b. Select the default named configuration and select advanced from the Show drop-
down list.
To cause a stack trace file to be created, set the environment so that a crash occurs in the
Forms Runtime when the user clicks any button.
a. In Oracle Enterprise Manager, navigate to the summit.env environment file and click
Add.
b. In the Add dialog box, enter the FORMS_DELIBERATECRASH environment variable with
a value of 2 and click Create.
c. Click Apply.
d. Run the Summit application in a browser and click any button to crash the Forms
Runtime process (frmweb.exe).
Open the stack trace file that was created as a result of the Forms crash and examine its
contents.
a. In Windows Explorer, navigate to
<ORACLE_INSTANCE>/FormsComponent/forms/trace and open the most recent
dump file in Notepad or WordPad.
Hint: Change the file name to add the extension .txt to easily open the file.
f. Click Apply.
Tasks
1. Configuring a Forms Trace
d. Click Apply.
Run the Summit application with the “summit” trace implemented. Test all of the actions that
are included in the trace.
a. Enter the following URL in a browser:
http://localhost:8888/forms/frmservlet?config=summit&record=forms&tracegrou
p=summit
b. Click Customers.
c. Select the Account Information tab and select a new account manager from the
c. If you receive an error indicating that the browser cannot display the web page, copy
the URL shown at the top of the page.
d. Paste the copied URL into another browser window and change the port to 8888.
g. When you are through examining the log, close its browser window, exit the Summit
form, and close its browser window.
h. In Enterprise Manager, refresh the User Sessions page. You can see that the log is no
longer visible from Enterprise Manager
4. Converting Forms Trace Output
When the user session is closed, its trace log is no longer available for viewing from
Enterprise Manager, but the file still exists on the file system. Use the Xlate utility to convert
the Forms Trace file into an HTML format. Create it in the same directory as the trace file,
with the same file name, but with an .htm extension.
Note: Commands in this section are listed in the file Practice12.txt, located in your lab
files directory. You can copy the commands and paste them into the command prompt
window.
a. Open a command prompt and set the following (substituting your own values for the
values in italics):
Environment Values
Variables
PATH <Oracle_Home>\jdk\bin
b. Enter the command to translate the trace file; for example (substituting your own
values for the values in italics):
java oracle.forms.diagnostics.Xlate datafile= <Oracle_Instance>\
FormsComponent\forms\trace\<trace_filename>.trc outputfile=
<Oracle_Instance>\FormsComponent\forms\trace\<trace_filename>.htm
outputclass=WriteOutHTML
c. In Windows Explorer, double-click the .htm file that the Xlate utility created to open it
in a browser.
d. You can see that the format of the file is different from the TEXT format used by
Enterprise Manager, but that the file contains the same information.
Tasks
1. Examining the Default Configuration of Servlet Logging
In Oracle Enterprise Manager, determine the default logging level, and run a couple of
Forms sessions to see the information that is logged.
a. In Oracle Enterprise Manager, click a WLS_FORMS link on the Farm home page.
c. On the Log Configuration page, select the Log Levels tab, and then expand the
following nodes: Root Logger > oracle > oracle.forms. You can see that the Logging
Level for oracle.forms.servlet is set to NOTIFICATION:1 (INFO) by default.
g. Select all of the Message Types check boxes and click Search. Depending on what
you have done in previous recent Forms sessions, you may see that no messages
match the criteria.
2) On the Log Files page, select formsapp-diagnostic.log and then click View Log
File.
3) On the View Log File page, scroll through the messages. You can see that only
errors, such as Runtime termination, and notifications, such as servlet
initializations, appear in the log.
In Oracle Enterprise Manager, change the Forms logging level to session. Examine the
results on current and new sessions.
a. Navigate back to the Log Configuration page (see Task 1, steps (a) through (c) above.)
b. For the oracle.forms.servlet node, select NOTIFICATION:16(CONFIG) from the
Oracle Diagnostic Logging Level (Java Level) drop-down list.
f. As before, examine the log messages. You should see information about the session
ending and the new session starting.
Set the Forms Listener Servlet logging level for the Summit application to
session/performance sessionperf, and then examine the results.
a. In Oracle Enterprise Manager, modify the summit configuration in the Forms Servlet
configuration file to override serverURL and set it to
forms/lservlet/sessionperf.
b. Perform a few actions in one of the existing Forms session and then exit the session.
Copyright © 2011, Oracle and/or its affiliates. All rights reserved.
c. Start a new Forms session with config=summit, perform a few actions, and then exit
the session.
d. Examine log messages again. You should see a performance summary for the session
just ended.
f. Look at the servlet log in Enterprise Manager. You should see many more messages
displayed.
Run the Summit application in multiple user sessions and simultaneously view the
Performance Summary in Oracle Enterprise Manager.
a. Close any existing Forms applications that may be running.
b. In Enterprise Manager select Monitoring > Performance Summary from the Forms
menu.
h. Rearrange the graphs by dragging the bar at the right of one of the graphs and
dropping it at the desired position.
2) Click 15 minutes link at the top of the graph to change the display to a 15 minute
time period.
j. When you have finished examining the performance metrics, you can exit all of the
running Forms sessions.
2. Examining Logs
c. The Log Messages window initially displays only the messages from the formsapp-
diagnostic.log file. Click Broaden Target Scope to show all logs from the
ClassicDomain WebLogic domain.
d. Select one of the messages and click View Related Messages > By Time.
f. You can add or remove columns in the display by selecting View > Reorder Columns.
Tasks
1. Deploying the Image File
The application developer has provided you with mysplash.jpg to use for the splash
screen. This image is in your lab files directory. Deploy it to the \forms\java directory on
the middle tier.
a. In Windows Explorer, navigate to the \files subdirectory of your lab directory.
b. Right-click mysplash.gif and select Copy.
Set the Forms Servlet configuration to use the splash screen as the Summit application
loads.
a. In Oracle Enterprise Manager, select Web Configuration from the Forms menu.
b. Select the [summit] named configuration.
c. Override the splashScreen parameter, set its value to mysplash.jpg, and click Apply.
d. Run the Summit application again. You should see the splash screen display as the
application initializes.