- · pdf file oracle application framework diagnostics ... • utilizes jdeveloper to...

61

Upload: hoangquynh

Post on 29-Mar-2018

232 views

Category:

Documents


2 download

TRANSCRIPT

<Insert Picture Here>

Oracle Application Framework Diagnostics

George Kellner

Senior Director, Application Technology Group

The following is intended to outline our general product direction. It is intended for information

purposes only, and may not be incorporated into any

contract. It is not a commitment to deliver any material, code, or functionality, and should not be

relied upon in making purchasing decisions.The development, release, and timing of any

features or functionality described for Oracle’s products remain at the sole discretion of Oracle.

<Insert Picture Here>

Agenda

• What is the OA Framework

• Diagnostic Tests

• Application Context Information

• Diagnosing User Interface Problems

• Personalization Diagnostics

• Extensibility Diagnostics

• Diagnosing Unexpected Errors

• Logging

• Database Connection Usage

• SQL Tracing

• Caching Diagnostics

<Insert Picture Here>

What is the OA Framework

Oracle Application Framework

• Complete application development platform

• Based on J2EE concepts – XML and Java

• Utilizes JDeveloper to build and debug applications

• Development methodology is metadata oriented

• Java interfaces available for complex logic

OAF Architecture

OAControllerOAController

BC4JBC4J OAF/UIXOAF/UIX

The Model is implementedusing BusinessComponents for Java(BC4J)

The View is defined usingOA Framework metadata,

rendered using UIX

The Controller is an OA FrameworkJava interface with two main methods:processRequest, processFormRequest

•OA Framework rendering engine links the Model runtime data to the View.•OAF leverages Application Object Library (AOL) infrastructure for connection pooling, security, menus, etc.

BC4J

• BC4J is multilayered to maximize separation of business logic / DML from data shaping and selection

• Entity Objects encapsulate the definition and business rules (validations, actions) associated with a row in a

database table

• View object encapsulates a database query. After a

query is executed, a view object provides iteration

over the result set

Runtime Capabilities

• Certified on popular browsers and hardware platforms

• Windows, Internet Explorer, Mac/Safari, Linux, Mozilla/Firefox

• Printable output and email content

• Same platform can be used for mobile applications

• Pocket PC, Palm, Blaze

• You can modify the ‘Look’ of Oracle EBS Applications through the Custom Look and Feel editor

Runtime Capabilities

• Example of PPR action to implement field level validation.

Update Ratefrom 50 to 60

<Insert Picture Here>

Diagnostic Tests

Basic Diagnostic Tests

• Verify Web Server configuration is working

• http://hostname:port/servlets/Hello (11i)

• http://hostname:port/servlets/ServletPing (R12)

• http://hostname:port/OA_HTML/OAInfo.jsp

• http://hostname:port/OA_HTML/OA.jsp?OAFunc=OAHOMEPAGE(R11i)

• http://hostname:port/OA_HTML/AppsLocalLogin.jsp

• http://hostname:port/OA_HTML/AppsLogin (R12)

• http://hostname:port/OA_HTML/jsp/fnd/aoljtest.jsp

AOLj Diagnostic Tests

<Insert Picture Here>

Application Context Information

About Page Context Information

AOLj Context Information

http://hostname:port /OA_HTML/jsp/fnd/aolj_setup_test.jsp?dbid=fwk12dev

<Insert Picture Here>

Diagnosing User Interface Problems

Diagnosing User Interface Problems

• Pages are not rendering properly

• Run same page on a more recent browser version or different browser entirely

• Make sure JavaScript is enabled on browser

• Turn off Partial Page Refresh - FND: Disable Partial Page Rendering - Yes

• Turn off accessibility - Self Service Accessibility Features (None) - Available from Preferences

Diagnosing User Interface Problems

• Pages are displayed but subsequent requests fail

• Check to see if cookies are enabled on the browser settings

• Turn on warn cookies option in browser to make sure cookie domain is scoped with the appropriate domain

• Check SESSION_COOKIE_DOMAIN column inicx_parameters table to check registered domain

Diagnosing User Interface Problems

• Pages are displayed but PPR actions fail

• Make sure you are using a modern browser (IE 6, Netscape 7+, Firefox 1.5+, etc)

• Turn on FND: Enable Partial Page Rendering Debugging Profile option to monitor partial target results

• LOVs or pop-up windows are not working

• Make sure all pop-up blockers are disabled

• Disable Yahoo! toolbar

<Insert Picture Here>

Diagnosing Personalization Problems

Diagnosing Personalization Problems

• About this Page link shows document path and all personalization documents

• MDS pages saved under <prod_top>/mds/comp/sub/file.xml

• XML files imported into MDS repository at customer site

Diagnosing Personalization Problems

• Use the Functional Administrator Responsibility / Application Catalog Tool to disable individual

personalization documents

• Turn off personalizations for the entire instance by

setting the following profile to ‘Yes’

• Disable Self-service Personal / FND_DISABLE_OA_CUSTOMIZATIONS

Diagnosing Personalization Problems

Diagnosing Personalization Problems

• Use SQL*Plus to see personalization registration

• Turn on diagnostic messaging in SQL*Plus

• SQL> set serveroutput on

• Review what personalization documents exist for a

given page

• execute jdr_utils.listcustomizations ('/oracle/apps/fnd/wf/worklist/webui/FullWorklistPG');

Diagnosing Personalization Problems

• Review a personalization document

• execute jdr_utils.printdocument ('/oracle/apps/fnd/customizations/user/2662/wf/worklist/webui/FullWorklistPG');

• Delete a personalization document

• execute jdr_utils.deletedocument ('/oracle/apps/fnd/customizations/user/2662/wf/worklist/webui/FullWorklistPG');

<Insert Picture Here>

Diagnosing Extensibility Problems

Diagnosing Extension Problems

• Make sure to import the .jpx file with the substitution into MDSusing JPXImporter

• Use the ‘About this Page’ link to find all dependent objects andmake sure substitutions of your extended objects were successful

• Enabled through FND_DIAGNOSTICS profile

• Check to see if substitution file was uploaded

• execute jdr_utils.listcustomizations (‘/oracle/apps/fnd/framework/toolbox/tutorial/server/customizations/site/0/’);

• Review a substitution definition

• execute jdr_utils.printdocument ('/oracle/apps/fnd/framework/toolbox/tutorial/server/customizations/site/0/PoSummaryVO’);

<Insert Picture Here>

Diagnosing Unexpected Errors

Diagnosing Unexpected Errors

• Error is raised by underlying application or OAF infrastructure.

• By default only a generic message without details

• Get the stack trace which tells more about the details

from the exception.

• Use profile FND: Diagnostics = Yes to obtain the

‘Click here for exception details’ link

• OACoreGroup<x>.err should also include a stack

trace for the exception

Diagnosing Unexpected Errors

• Use built-in logging infrastructure to help identify problem

• Enable logging

• FND: Debug Log Enabled profile set to ‘Yes’

• Turn on low level statement logging for a single user to monitor

• FND: Debug Log Level= Statement

Diagnosing Unexpected Errors

• Run the absolute minimum number of steps to reproduce problem

• Log in as system administrator and click on System Administrator responsibility

• Click on the Oracle Application Manager -> Logs function

• Enter User and log level=4-Exception and click Go button

• Log level=1-Statement provides valuable information

• Log level=2-Procedure is developer oriented

Diagnosing Unexpected Errors

<Insert Picture Here>

Logging

On Screen Logging

Enable FND Debug

• Another way of gathering the same info is the following:

• At the end of the existing URL add:

• &aflog_level=<log level>&aflog_module=*

• Use '*' for wildcard, not '%'. '%' is a special URL character)

• Example:

• http://host:port/OA_HTML/OA.jsp?OAFunc=OAHOMEPAGE&aflog_level=STATEMENT&aflog_module=fnd.common*

BC4J Logging

• BC4J diagnostics is now fully integrated with FND logging in R12

• You can direct BC4J logging to same destination and control it using the same profile options as FND

logging

• Prior to Release 12, if you enabled BC4J diagnostics

by setting -Djbo.debutoutput=console BC4J log

information is written to jserv log files.

• BC4J log information now shares the same

destination and content is correlated with rest of FND logging output.

BC4J Logging

• Module name for BC4J log statements is jbo and the level is always statement

• BC4J diagnostics can now be controlled at runtime, system-wide or for a particular user

• You can enable all these features by setting the following oc4j property (will be set by autoconfig in

R12)

• Djbo.debugoutput=oracle.apps.fnd.framework.server.OADiagnostics

<Insert Picture Here>

Database Connection Usage

Database Connections

• Database connection usage continues to be a major concern for larger customers

• Multiple pools maintain instances of these valuable resources

• Having a pool reduces the cost of creating and initializing new connections

• AOLj connection pool manages overall JDBC connection list

• Specialized connections are created for Application

modules to maintain parsed SQL statements

Database Connections (OAM)

Database Connections (OAM)

Database Connections (SQL)

• Show Connection Usage Per Module and processselect count(*), machine, process, module

from gv$session

group by machine, process, module

order by 1 asc

/

COUNT(*) Machine Name Process ID Module Name

---------- ------------------------- ---------- ------------------------------------------------

1 ap617cmr 20206 ? @ap617cmr (TNS V1-V3)

1 ap680jvm.us.oracle.com RT32124 fnd.framework.server.OAApplicationModule

1 ap680jvm.us.oracle.com RT32124 fnd.framework.navigate.server.OANavigatePortl:R

1 ap685ses.us.oracle.com 1234 fnd.framework.toolbox.tutorial.server.HomeAM:R

1 ap685ses.us.oracle.com 1234 fnd.framework.toolbox.tutorial.server.SearchAM:R

1 ap680jvm.us.oracle.com RT32124 fnd.framework.server.OAApplicationModule:R

1 ap685ses.us.oracle.com 1234 fnd.framework.server.OAApplicationModule

1 ap685ses.us.oracle.com 1234 fnd.framework.toolbox.tutorial.server.CreateAM:R

1 ap685ses.us.oracle.com 1234 fnd.framework.toolbox.samplelib.server.Sample:R

1 ap685ses.us.oracle.com 1234 fnd.framework.toolbox.tutorial.server.HelloWorld

1 ap680jvm.us.oracle.com RT32124 fnd.framework.toolbox.tutorial.server.SearchAM

AM Pool Profiles

• FND: Application Module Pool Enabled

• Indicates whether Application Module pooling is enabled. Set to ‘Yes’ by default.

• Transactions are processed faster since AM’s are recycled rather than recreated

• Connections are reinitialized less frequently

• More memory is consumed since AMs are cached

• More DB connections are used since connections are held

• Many AM Pool related profiles but stick with the

defaults unless instructed otherwise.

AM Pool Profiles

• FND: Application Module Connection Pool Enabled

• Indicates whether the connection associated with an Application module is checked in on AM checkin. Set to ‘No’ by default.

• Can release connection after page rendering if application has no state saved in database connection

• Uses fewer database connections (more scalable)

• Connections must be reinitialized more frequently (slower performance)

AM Pool Monitor

AM Pool Monitor

AOLj Connection Pool

<Insert Picture Here>

SQL Tracing

SQL Tracing

SQL Tracing

fwk12qa_ora_10969_SYSADMIN.trc

SQL Tracing

• How to locate trace file

• Trace file location is set using init.ora parameter user_dump_dest.

• How to analyze trace file

• Use tkprof to generate a report for SQL statements issued in trace file.

• What to look for

• SQLs with high response times, bad execution plans, high buffer gets/disk reads, high execution/parse count, high number of rows returned, etc…

<Insert Picture Here>

Caching Diagnostics

Caching Infrastructure

• Improve performance and scalability by maintaining common data with well defined characteristics

• Utilizes Java Object Cache infrastructure

• Supports distributed updates to this cached data

• Utilizes Workflow Business Event System to propagate updates

• Verifying caching infrastructure

• Run cache diagnostics

• Cannot target diagnostics for specific JVMs until R12

• Login to EBS as System Administrator

Caching Infrastructure

• Select System Administrator Responsibility

• Click on Oracle Applications Manager -> Diagnostics

• Click on the Focus icon for CRM Foundation

• Click on the Select checkbox for the Caching

Framework option and click on ‘Run’ button

• Click on the Next button in the Configure Test Page

• Click on the Submit button in the Review Page

• Cache Diagnostic Test and Cache DB Invalidation

Test should both return with status ‘Succeed’

• Click on Status icon to review diagnostic output

Caching Infrastructure

Caching Infrastructure

• Verify caching infrastructure

• Check that the active member list for each JVM is identical

• Check that the JVMs are using the same distributed cache listener port.Make sure that all the JVMs are running on distributed cache mode.

• If pages do not render then check status of JVM processes.

• Run a top on the JVM processes.

• If a JVM looks like it’s idle then it might be hung based on distributed cache infrastructure issue

For More Information

http://search.oracle.com

Oracle Application Framework

or

http://www.oracle.com/

The preceding is intended to outline our general product direction. It is intended for information

purposes only, and may not be incorporated into any

contract. It is not a commitment to deliver any material, code, or functionality, and should not be

relied upon in making purchasing decisions.The development, release, and timing of any

features or functionality described for Oracle’s products remain at the sole discretion of Oracle.