Your SlideShare is downloading. ×
Oracle adf performance tips
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Oracle adf performance tips

870
views

Published on

This paper provides various performance optimization tips in Oracle ADF applications

This paper provides various performance optimization tips in Oracle ADF applications

Published in: Technology

1 Comment
5 Likes
Statistics
Notes
  • Very useful for ADF projects
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Views
Total Views
870
On Slideshare
0
From Embeds
0
Number of Embeds
4
Actions
Shares
0
Downloads
0
Comments
1
Likes
5
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. ORACLE ADF PERFORMANCE TIPS An Oracle white paper Vinay Kumar Abstract This paper provides various performance optimization tips in Oracle ADF applications
  • 2. Table of Contents Tune ADF Model Layer.................................................................................................................................2 Tune ADF Faces UI Layer ..............................................................................................................................4 Tune ADF Controller layer............................................................................................................................7 General Tips –...............................................................................................................................................8 About the Author......................................................................................................................................8
  • 3. Tune ADF Model Layer  Use Bind Variables instead of where clause in VO query.  Avoid writing more complex logic in backing beans, instead redirect/move business logic to associated AMImpl.  Use VO based on entity object , only when you are doing DML operations  This is only for Transient View objects - General -> Tuning -> Ensure to check ONLY 'No Rows' options rest all unchecked , also check ' Passivate State' option.  Close rowSetIterator in end.
  • 4.  Never ever use ApplicationModule Locator to get the instance of any application module anywhere in the project except in Web services project. Implement Nested application module technique if there is requirement to get instance of any application module.  Make sure to have unique/Primary key defined on every View Object.  Use Programmatic VO's ( Transient VO's) only if required.  If any ViewObject dragged onto page fragment as component, Make sure fetchSize should be #{bindings.MyView.rangeSize} - Good practice to keep fetchSize as low as possible.  Avoid storing data in Session Scope.  If there are any common LOV's being used in respective page fragments and as independent components, then define them in 'faces- config.xml' and use wherever needed instead of binding to each page fragment  Ensure not to have any member level variables at application module level.  Never use getRowCount() unless it is really needed.  Use a read-only View Object if the View Object does not have to insert or update data.  Close unused rowsets.
  • 5.  If some data is static and used at multiple places then, cache data can be collected using a shared application module. Define in one application module and reuse using share application module. Tune ADF Faces UI Layer  While using tree or table, always consider set correct fetch size( fetch size - defines the number of rows to be sent to the client in one round- trip).  While using tree or table ,use appropriate content delivery mode  Possible values for this attribute are: immediate lazy whenAvailable  Avoid inline usage of JavaScript/Cascading Style Sheets (CSS) whenever possible.
  • 6.  While using tree or table, always consider set correct fetch size( fetch size - defines the number of rows to be sent to the client in one round- trip).  Avoid binding UI components in backing beans, if used make them as transient  Minimize the Number of Application Module Data Controls.  While using tree or table use column stretching, if really required.  Use "blocking=true" for and to avoid multiple clicks on submit buttons.  If you use, af:region and the jsff page fragment files have more than 1 root component, optimize it by arranging these components with a single root component. For example, if you want your region contents to stretch, you might have one visible content component and a series of popup components, put the visible content component inside of a “center” facet of an af:panelStretchLayout and put all of those popups in the “bottom” facet but also make sure to assign bottomHeight=”0px”. If you don’t want the contents to stretch, simply wrap these components with an af:panelGroupLayout layout=”vertical”.  Remove unused items from page bindings.
  • 7.  Minimize use of components that provide overflow popups, e.g. af:panelAccordion, af:panelTabbed, af:toolbar, af:breadCrumbs, af:menuBar. If you have to use these components, make sure that your target screen size can accommodate the content without having to invoke overflow  Set Immediate Property to True when Appropriate.  Remove unused VOIterators on JSFF Page definitions.  Use AJAX (PPR) as much you can.  Never use normal html tag with ADF face component.  Minimize use of components that provide custom title text truncation, e.g. af:panelHeader and af:showDetailHeader. If you have to use these components, make sure that your target screen size can accommodate the title text without having to truncate.  Ensure none of Page definitions should have more than one data control if not needed. This may result in increasing number of database connections.  Avoid using a af:panelStretchLayout where topHeight, bottomHeight, startWidth, or endWidth is set to “auto”.  Don’t ignore the warnings that JDeveloper gives you.  Don’t use JSF/ADF Faces and JavaServer Pages Standard Tag Library (JSTL) tags together.  Use the "visible" and "rendered" attributes wisely. o The visible property specifies simply whether the component is to be displayed on the page, or is to be hidden. o The rendered property specifies whether the component shall exist in the client page at all.
  • 8. Tune ADF Controller layer  Ensure to define same scope ( Pageflow,Backingbean) for a backing bean across all .jsff , task flows and adfc-config.cml.  Reuse task flow as much you can.  Best practice to define Navigational flows in the task flows instead of using NavigationalHandler in backing bean scope to define the Navigation.  Ensure each backing bean/Manage bean should implement java.io.Serializble interface.  Keep the managed beans in the lowest possible scope.
  • 9. General Tips –  Use oracle.adf.share.logging. ADFLogger to log all debugging messages which gives more control on the logging part.  Preferred changes in web.xml – org.apache.myfaces.trinidad.resource.DEBUG -False oracle.adf.view.rich.CHECK_FILE_MODIFICATION -False oracle.adf.view.rich.CLIENT_STATE_METHOD -token oracle.adf.view.rich.LOGGER_LEVEL -False or remove this entry oracle.adf.view.rich.ASSERT_ENABLED -False or remove this entry About the Author Vinay Kumar is a Senior Consultant and certified Oracle ADF/WebCenter Portal implementation specialist with Silbury IT Solutions gmbH. An Oracle Fusion Middleware evangelist. Vinay has seven years of experience consulting in Oracle ADF, Oracle WebCenter Portal/Content.