Showing posts with label UKOUG. Show all posts
Showing posts with label UKOUG. Show all posts

Monday, December 8, 2014

ADF Mythbusters UKOUG'14

I would like to post the slides from our recent session on UKOUG'14 conference - ADF Mythbusters. This session was presented by my colleague from Red Samurai Consulting - Florin Marcus. The goal was to break popular ADF myths. We have logged Oracle Support SR's, each myth in the slide is assigned with SR number.

Slides are available on SlideShare:


The following topics are covered in the presentation:
  • ADF BC Batches Of Functionality
  • AM Pools and DB Connection Pools
  • Activation-Safe Application Modules
  • Maximum Number of Regions Per Page
  • JSP vs Facelets
More detailed description and analysis data are available in the slides.

Sunday, December 8, 2013

ADF Development Survival Kit - Essentials for ADF Developer

This post is about our second session on UKOUG Tech13 conference. We were presenting and describing essential tools for successful ADF development. These tools are not available from Oracle, but can be implemented by yourself. I'm going to give a walk through for our session in this post.


1. Red Samurai Performance Audit

We believe monitoring of ADF BC and interaction with DB is the key for ADF application performance tuning. This is why we focus primarily on ADF BC and offer statistical information not available through Oracle Enterprise Manager and DMS servlet out of the box.

We offer this ADF performance audit tool for our customers only, there is no direct download. However, you can send me email with your request - you should describe ADF performance problem you want to fix, I will evaluate it and send install files to you.

Here you can see main dashboard for performance audit, displaying overall system performance - all transactions, logged users, query distribution per AM, number of users vs. number of activations:


Every Application Module performance is displayed using ADF dial gauge component:


We log following statistic for slow ADF performance:


Even more:


Overall performance overview:


This is how our audit is implemented (you can see more details in slides). Our ADF BC generic classes are injected into ADF application, statistical information is written to DB through separate thread. There is separate ADF application implemented as dashboard to review logged statistics:


2. PL/SQL code reuse

We were presenting custom made JDeveloper extension to call PL/SQL logic through declarative way, avoiding writing Java logic over and over again:


If you are interested in demo application and see how it works, let me know by email:


3. Semi-Automated Business Logic Reuse for Forms modernisation

Semi-Automated process was presented based on generic DB Validator to simplify PL/SQL or Web Service logic reuse in ADF applications. Here you can see diagram, send me email if you are interested in more details:


4. OJAudit extension for JDeveloper

Finally, we were presenting our extension for JDeveloper, implementing a set of custom OJAudit rules. We are going to merge it with ADF EMG OJAudit extension available for public download.

Tuesday, December 3, 2013

ADF Anti-Patterns: Dangerous Tutorials - Real Experience in ADF

Florin and me were presenting two sessions on UKOUG - UKOUG Tech13 - Red Samurai Real ADF Experience Sessions. There was quite a lot of content described and demoed, this is why I decided to split it into two different posts. This post will be about ADF Anti-Patterns: Dangerous Tutorials. The main idea behind this session was to describe most common misunderstanding hidden by typical ADF tutorials available on the Web.



We have prepared special app for this session, separating each use case into different module. You can download complete sample application - DangerousApp.zip.

Here is the picture of us presenting:


You can check uploaded slides for more details, below I will describe in addition every point presented. All the code listed is part of sample application, you can download it and check directly.

1. Batches Of and Slow Query

I believe you had experienced such situation, when SQL query was executed fast in SQL Developer, but slow in ADF. You should remember - ADF is executed from the server and there is additional roundtrip to bring data from DB. Also it depends how many rows are fetched in result set from DB to the server. By default, Batches Of property is set to 1:


We recommend to increase it for better performance and communication between WebLogic server and DB - this would allow to bring more rows in less roundtrips. There is a way to do this task in generic way, programatically - check the source code of sample application:


If you want to track time taken to execute VO, you could do this from the same executeQueryForCollection method - simply get start, end times and log:


2. Large Fetch

You can monitor row fetches performed in ADF with standard ADF BC method - createInstanceFromResultSet:


We would recommend to disable full table scroll by setting RowCountThreshold property for iterator in Page Definition to -1. Read more about this here: How To Disable SELECT COUNT Execution for ADF Table Rendering:


Make sure -1 is not set for LOV ListRangeSize property, otherwise it will be fetching all rows from DB, when LOV popup will be opened. Read more about it here: Fix Rowset is Forward Only Error for ADF BC LOV Range Paging (11.1.2.1.0):


3. Groovy Misuse

Keep in mind - when using Groovy function, it calls basic SQL statement, fetches records into memory and performs intended function. This would mean, it could fetch lots of rows into memory and only later produce requested result. Instead, you should consider using optimised SQL query directly for better performance, without using Groovy function.

Here is Groovy sum function example:


From the log you could see basic SQL statement executed and all rows fetched (2 rows in this example, it will be much more in real life scenario):


Another possible slow performance case with Groovy - calling Java method from Groovy attribute value expression. Especially if this Java method in turn is calling VO to fetch data from DB. The problem is related to numerous invocation of the same method by Groovy expression defined for attribute value. Here is example of such Groovy expression calling Java method from attribute value:


Java method is basically calling VO and executing it:


From the log we can see - VO was invoked and SQL executed at least two times in this example:


4. Passivation/Activation

When rendering ADF table, by default two requests are made. Between these requests, passivation/activation may happen and this going to slow down application performance. We could minimise this up to one request by setting ContentDelivery=immediate for ADF table, to prevent unnecessary passivation/activation. You can read more about it in this post: Immediate Effect for ADF Table Content Delivery:


ORDER BY and large fetch related issue was described in addition, it is document in this post: Reproducing WebLogic Stuck Threads with ADF CreateInsert Operation and ORDER BY Clause

5. ADF Query Misuse

Make sure not mix-up Bind Variables in VO, while using them from View Criteria. In this case I demo wrong scenario - Bind Variable is defined as Required, Where type:


This Bind Variable is used later from View Criteria. For Required, Where type Bind Variables, JDeveloper allows to choose Ignore Null Values option. Eventually this will break DB index usage, as IS NULL will be applied for the column:

Wednesday, November 27, 2013

UKOUG Tech13 - Red Samurai Real ADF Experience Sessions

UKOUG Tech13 conference is around the corner and we are completely prepared. My colleague - Florin Marcus and myself, will be presenting together our sessions this coming Sunday, December 1st at UKOUG Tech13 Super Sunday event. If you are around, please stop by and ask ADF questions - we are going to be more than happy to help you out.

I would like to post short summary about sessions we are going to present. There are two sessions:

1. ADF Anti-Patterns: Dangerous Tutorials


We are going to share very important hints, usually hidden behind typical ADF tutorials available on the Web and demo side-effects for various default ADF settings. This will be live ADF code session, each of the points will be explained directly in JDeveloper, without using boring Power Point slides.

There will be real ADF tuning tricks explained, collected through years of ADF experience.

2. ADF Development Survival Kit


Wouldn't it be great to hear how to build your own ADF Performance Audit Tool? We are going to explain how our ADF Performance Audit Tool works and even more important - how it is built, so you can build yours, once back home. Here is architecture preview to be explained:


We are going to focus on importance of PL/SQL code reuse while building ADF applications and modernizing Oracle Forms systems. There will be a demo, followed by detailed explanation how our PL/SQL reuse tool for ADF is implemented and how it works from ADF BC:


We are going even further than that - will be explaining Red Samurai process to reuse existing PL/SQL or Web Services code in ADF BC through automation and injection:


Thanks for reading my blog and hope to see you on UKOUG, will be extremely happy to chat with you - blog reader.

Wednesday, May 15, 2013

Grant Ronald and Susan Duncan for ADF Mobile SIG (UKOUG, London, May 21st)

ADF Mobile is one of the hot topics in ADF area currently. If you want to see it in practice and learn about ADF Mobile architecture, I'm sure you should join UKOUG SIG in London on May 21st. Check here for more info and registration link - UKOUG Run Full Day SIG on ADF Mobile.

Grant Ronald and Susan Duncan are well known Oracle speakers, they will host this event. I know there are few seats left, you should hurry to register.

Thursday, September 17, 2009

Oracle Development SIG in UK - Modernisation of Oracle Development Skills

On the 27th of October, I'm going to Oracle UK London City office. Will present there on Oracle Development SIG, this event is organized by UKOUG and replaces old Development Engineering SIG.

You can find event agenda and register on UKOUG site - Development SIG.

Main focus of this event is to describe the path of Oracle Forms modernization, using different approaches offered by Oracle - JDeveloper, SOA, Apex.

I will talk based on my Oracle OpenWorld 2009 presentation - Oracle ADF 11g Production Project Experience on Oracle Open World 2009.

Will be happy to meet you in London.