Skip to main content

Posts

Showing posts with the label ADF

Implementation of ADF XML Menu Model

This post will cover the coding details of implementing an ADF XML menu model. Do you need to manage all your navigation menus in a centralized file including its label, URL, title and other custom attributes you may have? If so, the solution is to use ADF XML menu model. ADF XML menu  model is the same concept as the built in WebCenter Navigation Model in Oracle WebCenter Portal. It uses a XML file to hold the navigation metadata - id, label, title, destination/url and other custom attributes you may need. The XML file is the data model layer. Using XML menu, you can generate various kinds of navigation user interface components, such as navigation links, bars, tabs, breadcrumbs, etc. You can also apply business logic to conditionally control the rendering of the navigation menu. The business logic including security can be applied at either the XML model layer or the UI presentation layer depending on where it fits your purpose. You can create multiple navigation hierarchy...

About adfc_diagram files in ADF

In short, files that end with "adfc_diagram" file type are metadata files to keep track of element position in an ADF task flow. ADF task flow offers a process-flow like visual panel for developers to re-position the elements (page/fragment, router, Java bean methods, etc). The file ending with "adfc_diagram" is the one tracking the positions of all elements so that next time the task flow is open the saved visual positions are presented. Another blog spot on the same matter: http://javalopez.blogspot.com/2015/03/should-i-commit-adfcdiagram-files.html

JDBC Connection Leak in ADF app on a WebLogic Server

It's an old topic but worthy to post as it happens frequent enough in codes that I observed. The bottom line of the issue that I am going to describe here is a coding issue, to it applies to WebLogic 11g as well as 12c. An ADF app deployed on a remote WebLogic Server went to an error page frequently. Checking the log, I found it's complaining on "JBO-26061: Error while opening JDBC connection". The next thing I did is checking the data source of the ADF App configured on the WebLogic Server console. On the Data Source -> Monitoring -> Statistics, the "Active Connection Average Count", "Active Connections Current Count" and "Active Connection High Count" all showed "15", which is the default max capacity of a connection pool. This shows all the connections are taken and no more connection available. I go to Monitoring -> Testing, select on the affected server and click on "Test Data Source", such error w...

Build A Concurrent Web Page With A Simple Example

Today, by using a simple example, I am going to demonstrate on how to build a concurrent web page in ADF using Jdeveloper. From time to time, I see requirements from various contexts with such needs to build concurrencies on web pages. The performance can be greatly benefited since multiple processes are executed at the same time so that the response time is greatly improved. It's also very suitable for the use cases that the processes are not associated with any user interface interactions, such as sending an email to user after performing some action but the web page does not need to know if/when the email is sent. Such processes can be executed in a separate thread from the main thread dealing with the web page rendering and other user interactions. Even if you don't have hard requirement on such concurrency needs, why waste it? Nowadays, all servers are built with multi-core computation capabilities and designed for parallel processing. In years the speed of the CPU is n...

Work with the ADF Control State on External Link URL in WebCenter Portal Navigation Model

In the Navigation Model of a WebCenter Portal application (11g), there is an option to define a navigation resource by "external link". In a normal case, you should NOT define any internal JSPX page using this option, but only if there is a need to navigate to a third party site - by what the name means, an external link. The internal JSPX page should be added to the Navigation Model by the "page" type. The impact of defining internal JSPX page as an external link is, the redundant memory footprint due to the ADF control state token recreations every time this external link is clicked. ADF control token is an identifier used by the Controller to track user's state so that all in process task flows for the same user can be retrieved. Normally, this ADF control state should be not recreated for the same user. With the external link type, the navigation behaves like entering the application in a blank new context so every navigation with external link type will ...

Understand WebCenter/ADF Session Invalidation and Removal

There are a couple of ways to invalidate the session in WebCenter Portal (or ADF) application. They are not the same. They all would invalidate the user session which is intended. The main difference is around whether the session will be removed after it's invalidated. In this post, I will walk through this. In WebCenter Portal framework application, the built-in page template already has a logout function provided. Let's take a look at it. Create a WebCenter portal application and open up the page template as below In this JSPX file, you will find a logout command link with action specified as "#{o_w_s_l_LoginBackingBean.doLogout}". The source code of this bean is not available unless you trace back to the shipped libraries that were installed with Jdeveloper. Let's take a look at the effect of the logout function. Run the portal application. Open the local weblogic console, navigate to the deployment, find your application, go to applicatio...

Build Responsive ADF Web Application - Kscope15 Session

My Kscope15 session - Build Responsive ADF Web Application - the presentation can be downloaded at  https://drive.google.com/file/d/0Bx-fIQETbpw5MXRreDRkLVktYzg/view?usp=sharing Thanks for those of you who provided the feedback.

Bypass the IE Compatibility Mode (IE8/9) in ADF/WebCenter App

Some times the IE compatibility mode is enforced to be used by your system admin at an enterprise level, especially for the intranet sites. Since Jdeveloper 11.1.1.6, a popup warning is shown to the user when ADF/WebCenter application is running on compat mode. The issues seen in compat mode is not supported by Oracle. The solution to bypass the compat mode has been documented via Oracle Doc 1555476.1. I'd like to extract the key information of the such solution here: A new feature has been introduced in JDeveloper/ADF 11.1.1.7.0 and 11.1.2.4.0 and backported to 11.1.1.6.0, 11.1.2.0.0, 11.1.2.2.0 and 11.1.2.3.0 through patch 14400317. It consists of bypassing Compatibility Mode in IE browsers. The ADF framework will force the target document to the maximum document mode supported by the browser using the X-UA-Compatible META tag. This applies to desktop browsers in compatibility view mode and also applications that use the IE WebBrowser component to host content within deskto...

WebCenter Portal HA and Performance Tuning Checklist

Performance is a broad topic which is never out of date. I'd like to itemize a checklist with specific topics, links and references. Some topic may be more generic and some may be more specific. But this list mainly focuses on WebCenter Portal applications and its relevant products. This is not intended to be a complete list and there will never be. WebCenter Performance Tuning Guide HA for WebCenter Portal and ADF application Configure JOC for WebCenter Portal services Configure Coherence Caching for Content Presenting WebCenter Performance Study (Including Enable Client Caching and Compression) Tuning JVM Weblogic Capacity Planning Middleware Performance Tuning Roadmap Oracle HTTP Server Performance Tuning MDS Performance Tuning Using Cluster and HA Features Some Useful A-Team Blog Posts: High availability considerations for WebCenter Portal and ADF   Improving ADF Page Rendering Time : Progressively Loading Taskflows Configure Coherence for Oracl...

Build an Image Slider in ADF/WebCenter Portal using jFlow Plus v2

In a modernized ADF/WebCenter Portal application, it's very common to have an image slider that can slide images automatically/manually from one to another. If you are thinking of implementing such functionality, my post here might help you. The image slider transition is implemented by JQuery. I will not focus anything on JQuery as there are many third party JQuery plugin out there for such image sliding effect. But those plugins are not ready to use for your ADF/WebCenter application, due to ADF technology itself which is based on faces components. Here I am presenting a working copy of such implementation. The plugin I used here is "jFlow Plus v2". You can download the plugin and find more info about it here: http://wordimpress.com/demos/jflowplus-v2/. To preview the finished version built on top of ADF, here is the screenshot: Here are several things I want to emphasize: Determine your page layout - flow layout or stretch layout. You always want to determin...

Set a PanelTab height dynamically using JavaScript

It's not a common scenario but interesting to note down what's the use case and how to implement it. The use case is to get the view port height on the ADF page and set height to the PanelTab or other component related to the view port height. Most sites are still designed with flow layout on fixed width of the page. Users would have all kinds of different desktop resolutions so that their browser would render the ADF pages a bit differently. Some with large resolution would have large blank space. To make the site more appealing (or even readable at least) and fit into different browser window sizes, we can definitely control the heights of ADF components using JavaScript. In this example, we will look at the PanelTab component but it can be applied to any other ADF components. There is actually a web design - responsive web design - supposed to solve these kind of problems and render the site in multiple platforms. But the solution in this blog is more or less a fix/worka...

Considerations on WebCenter/ADF Performance

Performance for WebCenter/ADF is always a hot topic. For every application (ADF web apps, WebCenter Portal/Spaces apps, or others), you will be ended up to deal with it sooner or later. Sooner is of course better, it's recommended to be considered at the time the project is plotted out since you will need to consider your budget for hardware/software acquisitions. I have experienced with couples of clients that requested to tune performance after the application went to production which is still OK but not the ideal time, simple because there are so many restrictions dealing with performance tuning after it went on production. The performance no doubt is a broad topic. This article will try to include a checklist of areas you need to bear in mind for the matter of performance in the WebCenter/ADF world, but will not go into very detail on each section. Performance is limited by many factors, such as hardware resource and the application architecture. The CPU type/speed,...