Skip Headers
Oracle® Application Server Containers for J2EE Servlet Developer's Guide
10g Release 2 (10.1.2)
B14017-02
  Go To Documentation Library
Library
Go To Product List
Product
Go To Table Of Contents
Contents
Go To Index
Index

Previous
Previous
Next
Next
 

7 Configuration with Enterprise Manager

In an Oracle Application Server environment, configuration of Web modules is performed through Oracle Enterprise Manager 10g. This chapter describes key features of Enterprise Manager for servlet and Web site configuration. It includes the following sections:

Web Module Configuration in Oracle Enterprise Manager 10g

The direct use of global-web-application.xml, orion-web.xml, and default-web-site.xml elements and attributes, described in Chapter 6, is for development and deployment in an OC4J standalone environment. In an Oracle Application Server environment, such as for production deployment, use Enterprise Manager for Web module configuration and deployment.

Oracle Enterprise Manager 10g Application Server Control Console is the administration console for an Oracle Application Server instance. It enables you to monitor real-time performance, manage Oracle Application Server components and instances, and configure these components and instances. This includes any instances of OC4J. In particular, Application Server Control Console includes pages to configure servlets and Web sites. Application Server Control Console comes with your Oracle Application Server installation. Log in as the ias_admin user.

This chapter covers relevant Application Server Control Console pages for managing and configuring Web modules in an OC4J instance within Oracle Application Server. Some of the pages allow you to alter global-web-application.xml, orion-web.xml, and default-web-site.xml settings. Other pages display web.xml settings, which you can override through orion-web.xml settings.

Each page description notes the corresponding elements and attributes in web.xml, orion-web.xml/global-web-application.xml, or default-web-site.xml. The elements and attributes for global-web-application.xml or orion-web.xml are documented in "Element Descriptions for global-web-application.xml and orion-web.xml". The default-web-site.xml elements and attributes are covered in "Element Descriptions for Web Site XML Files". For information about web.xml elements, refer to the servlet specification.

See the Oracle Application Server Containers for J2EE User's Guide for additional information about using Enterprise Manager with OC4J.

Application Server Control Console Page Descriptions

The following sections discuss key Application Server Control Console pages in Enterprise Manager for servlet and Web site configuration and deployment:

Application Server Control Console OC4J Home Page

When you first access an Oracle Application Server instance through Application Server Control Console in Enterprise Manager, you reach the Oracle Application Server Instance Home Page. Through this page, you can drill down to any of the running OC4J instances by selecting the name of the instance (home, for example) in the System Components table. Application Server Control Console then displays the OC4J Home Page for that instance.

Figure 7-1 shows portions of the OC4J Home Page for the home instance.

Figure 7-1 Application Server Control Console OC4J Home Page

Description of Figure 7-1  follows
Description of "Figure 7-1 Application Server Control Console OC4J Home Page"

From the OC4J Home Page, you can do the following:

  • Click Applications to access the Application Server Control Console OC4J Applications Page.

  • Click Administration to access the Application Server Control Console OC4J Administration Page.

Application Server Control Console OC4J Applications Page

Figure 7-2 shows the OC4J Applications Page, which enables you to deploy applications. You can reach this page by clicking Applications from the OC4J Home Page.

In particular, relating to topics covered in this manual, note the following:

  • Clicking the Deploy EAR file button accesses the Deploy Application Page.

  • Clicking the Deploy WAR file button accesses the Deploy Web Application Page.

Figure 7-2 Application Server Control Console OC4J Applications Page

Description of Figure 7-2  follows
Description of "Figure 7-2 Application Server Control Console OC4J Applications Page"

Application Server Control Console Deploy Application (EAR) Page

Figure 7-3 shows the key portion of the Application Server Control Console Deploy Application Page, which is the page for deploying an EAR file. Drill down to this page from the Applications Page of an OC4J instance by clicking the Deploy EAR file button.

Figure 7-3 Application Server Control Console Deploy Application Page

Description of Figure 7-3  follows
Description of "Figure 7-3 Application Server Control Console Deploy Application Page"

In the Deploy Application Page, click the Browse button to select an EAR file to deploy, then specify the desired J2EE application name, which is typically the same as the EAR file name without the .ear extension. You can also specify a parent application, but it is typical to use the OC4J default application as the parent.

Deployment results in a new <application> element being entered in the server.xml file.

When you click the Continue button, the Deploy Application: URL Mapping for Web Modules Page appears. This page enables you to set a URL context path for the Web application that the J2EE application contains. Figure 7-4 shows this page, with the default context path for the Web application of a J2EE application named utility. Clicking the Next button enables you to review your entries and then deploy.

Specifying a URL context path results in an entry in the default-web-site.xml file to bind the Web application to the Web site. This is accomplished through a new <web-app> subelement of the <web-site> element. In addition, the mod_oc4j.conf configuration file for the Oracle HTTP Server mod_oc4j Apache mod is updated with appropriate mount points.


Note:

In specifying the context path, the following forms are treated equivalently:
someUrl
/someUrl
/someUrl/

Figure 7-4 Application Server Control Console Deploy Application: URL Mapping Page

Description of Figure 7-4  follows
Description of "Figure 7-4 Application Server Control Console Deploy Application: URL Mapping Page"

Application Server Control Console Deploy Web Application (WAR) Page

Figure 7-5 contains the key portion of the Application Server Control Console Deploy Web Application Page, which is the page for deploying an independent WAR file. Drill down to this page from the Applications Page of an OC4J instance by clicking the Deploy WAR file button.


Note:

When you deploy an independent WAR file, it is wrapped in an EAR file transparently.

Figure 7-5 Application Server Control Console Deploy Web Application Page

Description of Figure 7-5  follows
Description of "Figure 7-5 Application Server Control Console Deploy Web Application Page"

In the Deploy Web Application Page, click the Browse button to select a WAR file to deploy. Then specify a desired J2EE application name along with a URL context path to map to the Web application. Transparently, a J2EE application by the specified application name is created to contain the Web application. In OC4J, any Web application must be contained in a J2EE application.

As with an EAR file, the deployment results in a new <application> element in the server.xml file. Additionally, to bind the Web application to the Web site, a new <web-app> subelement is added to the <web-site> element in the default-web-site.xml file. Finally, the mod_oc4j.conf configuration file for the Oracle HTTP Server mod_oc4j Apache mod is updated with appropriate mount points.


Note:

In specifying the context path, the following forms are treated equivalently:
someUrl
/someUrl
/someUrl/

Application Server Control Console OC4J Administration Page

Figure 7-6 shows the OC4J Administration Page, which enables you to access OC4J instance properties. You can reach this page by clicking Administration from the OC4J Home Page.

Clicking Website Properties under Instance Properties accesses the Website Properties Page, through which you can access a variety of pages to update Web module properties.

Figure 7-6 Application Server Control Console OC4J Administration Page

Description of Figure 7-6  follows
Description of "Figure 7-6 Application Server Control Console OC4J Administration Page"

Application Server Control Console Website Properties Page

Figure 7-7 shows the key portion of the Application Server Control Console Website Properties Page for an OC4J instance. Drill down to this page by clicking Website Properties under Instance Properties in the OC4J Administration Page.

Figure 7-7 Application Server Control Console Website Properties Page

Description of Figure 7-7  follows
Description of "Figure 7-7 Application Server Control Console Website Properties Page"

Among other things, this page enables you to specify whether each application should be loaded automatically when OC4J starts. (Otherwise, an application is not loaded until the first request for it.) This corresponds to the load-on-startup attribute of the appropriate <web-app> subelement of the <web-site> element in the default-web-site.xml file. (For general information about loading an application at OC4J startup, see "Servlet Preloading".)

From the Website Properties Page, drill down to the Web Module Page for any particular Web module. In the preceding sample page, for example, you can click webapp to drill down to the Web Module Page for that module.

Application Server Control Console Web Module Page

Figure 7-8 contains the key portion of the Application Server Control Console Web Module Page for the module webapp. Drill down to the Web Module Page for a particular module by clicking the module name in the Website Properties Page.

Figure 7-8 Application Server Control Console Web Module Page

Description of Figure 7-8  follows
Description of "Figure 7-8 Application Server Control Console Web Module Page"

From the Web Module Page, you can access several categories of Web module properties through the following links, under Properties in the Administration section of the page:

  • General to drill down to the Web Module Properties Page

  • Mappings to drill down to the Web Module Mappings Page

  • Filtering and Chaining to drill down to the Web Module Filtering and Chaining Page

  • Environment to drill down to the Web Module Environment Page

  • Advanced Properties to drill down to the Web Module Advanced Properties Page

Application Server Control Console Web Module Properties Page

Figure 7-9 and Figure 7-10 show portions of the Application Server Control Console Web Module Properties Page for a particular module. Drill down to this page by clicking General under Properties in the Administration section of the Web Module Page.

Figure 7-9 Application Server Control Console Web Module Properties Page (1 of 2)

Description of Figure 7-9  follows
Description of "Figure 7-9 Application Server Control Console Web Module Properties Page (1 of 2)"

Figure 7-10 Application Server Control Console Web Module Properties Page (2 of 2)

Description of Figure 7-10  follows
Description of "Figure 7-10 Application Server Control Console Web Module Properties Page (2 of 2)"

These settings correspond to orion-web.xml elements as follows.

In the General section:

  • Servlet Directory corresponds to the servlet-webdir attribute of the <orion-web-app> element.

  • Temporary Directory corresponds to the temporary-directory attribute of the <orion-web-app> element.

  • Response Buffer Size corresponds to the default-buffer-size attribute of the <orion-web-app> element.

  • File Check Interval corresponds to the file-modification-check-interval attribute of the <orion-web-app> element.

In the Session Configuration section:

  • Use Cookies corresponds to the cookies attribute of the <session-tracking> element, which is a subelement of the <orion-web-app> element.

  • Session Auto Join corresponds to the autojoin-session attribute of the <session-tracking> element.

  • Session Timeout corresponds to the <session-timeout> subelement of the <session-config> subelement of the standard <web-app> element. You can use a <web-app> subelement under <orion-web-app> in orion-web.xml for deployment-specific overrides of <web-app> settings in the application web.xml file.

  • Cookie Max Age corresponds to the cookie-max-age attribute of the <session-tracking> element.

  • Cookie Domain corresponds to the cookie-domain attribute of the <session-tracking> element.

  • Session Storage Directory corresponds to the persistence-path attribute of the <orion-web-app> element.

In the Class Paths section:

  • Adding a classpath here corresponds to setting the path attribute of a <classpath> subelement of the <orion-web-app> element.

In the Session Trackers section:

  • Adding a session tracker here corresponds to setting the servlet-name attribute of a <session-tracker> element, which is a subelement of the <session-tracking> element.

In the Virtual Directories section:

  • Adding a virtual directory here corresponds to setting the real-path and virtual-path attributes of a <virtual-directory> subelement of the <orion-web-app> element.

In the Tag Libraries section:

  • This section lists JSP tag libraries used in the application, according to contents of the WAR file.

Application Server Control Console Web Module Mappings Page

Figure 7-11 and Figure 7-12 contain portions of the Application Server Control Console Web Module Mappings Page for a particular module. Drill down to this page by clicking Mappings under Properties in the Administration section of the Web Module Page.

Figure 7-11 Application Server Control Console Web Module Mappings Page (1 of 2)

Description of Figure 7-11  follows
Description of "Figure 7-11 Application Server Control Console Web Module Mappings Page (1 of 2)"

Figure 7-12 Application Server Control Console Web Module Mappings Page (2 of 2)

Description of Figure 7-12  follows
Description of "Figure 7-12 Application Server Control Console Web Module Mappings Page (2 of 2)"

The following settings all correspond to subelements of the <web-app> element in the web.xml file. You can use a <web-app> subelement under <orion-web-app> in orion-web.xml for deployment-specific overrides of these settings. You can use the Advanced Properties Page for this purpose—see "Application Server Control Console Web Module Advanced Properties Page".

In the Servlet Mappings section:

  • A servlet name or URL pattern specified here corresponds to the <servlet-name> or <url-pattern> subelement of a <servlet-mapping> subelement of the <web-app> element.

In the MIME Mappings section:

  • A MIME type and extension specified here correspond to settings in the <mime-type> and <extension> subelements of a <mime-mapping> subelement of the <web-app> element.

In the Welcome Files section:

  • A file name specified here corresponds to the setting in a <welcome-file> subelement of the <welcome-file-list> subelement of the <web-app> element.

In the Error Pages section:

  • An error code and location specified here correspond to settings in the <error-code> and <location> subelements of an <error-page> subelement of the <web-app> element.

  • An exception class and location specified here correspond to settings in the <exception-type> and <location> subelements of an <error-page> subelement of the <web-app> element.

Application Server Control Console Web Module Filtering and Chaining Page

Figure 7-13 displays the key portion of the Application Server Control Console Web Module Filtering and Chaining Page for a particular module. Drill down to this page by clicking Filtering and Chaining under Properties in the Administration section of the Web Module Page.

Figure 7-13 Application Server Control Console Web Module Filtering/Chaining Page

Description of Figure 7-13  follows
Description of "Figure 7-13 Application Server Control Console Web Module Filtering/Chaining Page"

These settings correspond to orion-web.xml elements as follows.

In the Servlet Filtering section:

  • Adding a filter here is equivalent to setting the <servlet-name> or <url-pattern> subelement of a <filter-mapping> subelement under the <web-app> element. The servlet name you specify is tied to a servlet class through its standard configuration in the web.xml file.

In the Servlet Chaining section:

  • Adding a chain here is equivalent to setting the servlet-name and mime-type attributes of a <servlet-chaining> subelement of the <orion-web-app> element. The servlet name you specify is tied to a servlet class through its standard configuration in the web.xml file.


    Note:

    Servlet chaining is an older mechanism with essentially the same functionality as standard servlet filtering, which was introduced in version 2.3 of the servlet specification. It is advisable to use servlet filtering instead. See "Servlet Filters".

Application Server Control Console Web Module Environment Page

Figure 7-14 shows the key portion of the Application Server Control Console Web Module Environment Page for a particular module. Drill down to this page by clicking Environment under Properties in the Administration section of the Web Module Page.

Figure 7-14 Application Server Control Console Web Module Environment Page

Description of Figure 7-14  follows
Description of "Figure 7-14 Application Server Control Console Web Module Environment Page"

This page includes settings for servlet context parameter overrides, environment entry overrides, and resource references. The overrides indicate settings in the orion-web.xml file that override corresponding web.xml settings.

These settings correspond to web.xml and orion-web.xml elements as follows.

In the Servlet Context Parameters section:

  • This section displays settings of web.xml <context-param> elements that can be overridden for this deployment, along with any Deployed Value overrides that have already been specified. Enter a new value in the Deployed Value column to specify a new override. Doing so creates a <context-param-mapping> entry in orion-web.xml.

In the Environment Entries section:

  • This section displays settings of web.xml <env-entry> elements that can be overridden for this deployment, along with any Deployed Value overrides that have already been specified. Enter a new value in the Deployed Value column to specify a new override. Doing so creates an <env-entry-mapping> entry in orion-web.xml.

In the Resource References section:

  • This section displays a combination of web.xml and orion-web.xml settings. The name and type of a resource reference correspond to <res-ref-name> and <res-type> subelements under a <resource-ref> subelement of the <web-app> element in the web.xml file. The JNDI location and lookup context correspond to settings under a <resource-ref-mapping> element and its <lookup-context> subelement, under the <orion-web-app> element in the orion-web.xml file.

Application Server Control Console Web Module Advanced Properties Page

Figure 7-15 shows the key portion of the Application Server Control Console Web Module Advanced Properties Page for a particular module. Drill down to this page by clicking Advanced Properties under Properties in the Administration section of the Web Module Page.

You can use the Web Module Advanced Properties Page to edit orion-web.xml or global-web-application.xml for any settings not covered by the previously discussed Application Server Control Console Web module pages. In fact, you can make any orion-web.xml or global-web-application.xml entries through the Advanced Properties Page; however, use the previously described pages whenever possible because of their error handling and reporting features.

Figure 7-15 Application Server Control Console Web Module Advanced Properties Page

Description of Figure 7-15  follows
Description of "Figure 7-15 Application Server Control Console Web Module Advanced Properties Page"