Sunday, September 4, 2011

Webcenter : Setting Custom Skin and Template as Default.

 

When you create web center portal project it comes with default page template and default skins.

When you create your own page template and skins then you can override that value in adf-config.xml.

Note :-  Before overriding you have to add this skins by doing "Add Portal Resource” and then go to portal-preference and change the value of skin , template and more.

image

Webcenter : Integrate ADF Taskflow with Portal Application

 

In previous blog we simply created portal application which don’t even need to be blogged , however , it is easy some time for other reader to understand the basement.

Create Simple “Fusion ADF” Application with standard HR Schema with EO/VO for Employee , Department , Job , Regions.

Create Four Taskflow with one view fragment with name emp , dept , job , regions.

image

Create a deployment profile as ADF lib jar for this ADF application.

image

Once this ADF Jar is created add it to resource pallet –> IDE Connection –> File Systems –> adflibforportal 

image

image

As we can notice jar is added to File System , Right click and click “Add to Project”

image

Right click portal project and see project properties and click ADF Library –> Edit.

image

As you can see jar contains all taskflow.

image

Now double click navigation in portal and add following four task flow as link with Type on Navigation side as Task Flow.

image

click Default navigation model and click Link and associate it with taskflow as below from resource pallet.

image

Sam way add all four link and finally compile and run home.jspx.

When I ran the application , I see only two link Emp and Dept where are other two link Job , Region.

image

Go to Jazn-Data.xml and give authentication-role to job and region taskflow as below and re run the application.

image

Now we can see all four hyperlink.

image

This demo gives an example of power of reusability and modularity in ADF application with webcenter portal.

If we use same idea for bigger project then we can create new independent ADF projects like HR , Sales , Marketing and merge to portal application in independent taskflow with proper permission.

Wednesday, August 31, 2011

Webcenter : Creating Portal Application and Integration with ADF

 

I will demonstrate how to create web center portal application and consume ADF Task flows based on ADF BC component.

1. Create New WC Portal  Application

image

2. I am selecting default provided by portal.

image

3.You will see default portal structure is created with three data control.

image

Above project structure has following component

- Portal

site navigation , page hierarchies , administration , security , page templates , skins and more.

-PortalWebAssests

This folder is specially for static resources.

Run Home.jspx and you will see following default out of box login page.

image

login as weblogic/weblogic1

image

On top right corner there is “Administration” link which will take you to runtime webcenter navigation customization , create page and much more.

image

In next few blogs we will create our own portal components and new ADF Project to integrate it to portal project.

Webcenter Warning :- Make Sure Your Domain Directory ?

 

When we create webcenter domain make sure it do not contains any spaces in between.

Also , make sure domain is present in folder which do not have spaces in between.

Consequences :- if you have above two point satisfied in your webcenter installation and configuration then pages in webcenter application will not be rendered.

Webcenter : How to verify that you have Webcenter Extension Installed

 

Open Jdeveloper

Help –> About (Click Extensions) and sort by Identifier two times.

You will see version of each component of webcenter like Oracle Composer , Webcenter Rss Services etc.

image

Tuesday, August 30, 2011

Weblogic : Taskflow do not show latest changes after running

 

When you add execute with parameter or new view to task flow run the project then some time I have seen that new taskflow changes are not reflected in running application.

Then you will do following things without any success

- Restart Integrated Weblogic Server

- Restart Jdeveloper

- Clean Project

However , still Task Flow changes are Old.

So what do I do next.

For web Logic there is domain and you can see current running domain by looking in to your J-developer log window.

image

So go to System directory Directory

C:\******\system11.1.1.4.37.59.23

Delete Project inside DRS folder

C:\**\system11.1.1.4.37.59.23\o.j2ee\drs

Result :- when you run project again you will see latest changes of your taskflow.

Delete Project inside ADRS folder

C:\***\system11.1.1.4.37.59.23\o.mds.dt\adrs

This will delete some mds stuff.

Tuesday, August 23, 2011

Weblogic : Identifying Class Conflict and ClassLoading in deployed ADF Application using CAT Tool in Weblogic

 

List of Class Loader in Weblogic

System Class Loader - Weblogic Classes in weblogic system directory

Domain Class Loader - Domain Classes in domain directory

Application Class Loader - Library from Weblogic-application.xml , APP-INF/lib

WEB APP Class loader - Library from weblogic.xml , WEB-INF/lib , WEB-INF/classes

JSP class loader

Class Conflict

Until Weblogic 10.3.4 there was no tool available in weblogic  to identify class conflict. However , Now weblogic has a tool called CAT (Classloader Analysis Tool) to perform class conflict check.

Let us say you have class call ClassLoadingExample.class in your Ear Application $CLASSPATH.

Also, you have same class in $CLASSPATH of weblogic.

So when you run the application then Weblogic class will be considered ,not the EAR one giving you surprising result.

Filtering Class Loader

This provide us option to configure our deployment description to make sure that our WAR/EAR class are loaded ,not the one in weblogic.

FilteringClassLoader sits between Application and System Class loader. It is child of System Class Loader and Parent of Applicatino Class Loader.

FilteringClassLoader intercept loadClass method and compare className with list of package specified in weblogic-application.xml file. If package matches class name , FilteringClassLoader throws ClassNotFoundException. This exception notifies applicatino classloader to load class from application.

Configure Filtering Class Loader

Add prefer-application-packages description in weblogic-applicatino.xml which detail is of package to be loaded from application.

<prefer-application-packages>  
<package-name>thirdparty package in your application which may be in weblogic</package-name>
</prefer-application-packages>

Installing CAT


CAT is a Web-based class analysis tool provided by weblogic and we need to deploy wls-cat.war which is located in “WL_HOME/server/lib/wls-cat.war”


After deploying it can be accessed in.


http://weblogichost:port/wls-cat/


CAT Display all currently running applications and modules.


You can use this tool to check Classloading conflicts , Check system and application classloaders and even generate report. For further information please refer to oracle documentation.


For me wls-cat.war is located in


image


I login to weblogic console


http://localhost:7101/console


image


Install war as application , not as lib.


image


Finally deployed with following context


image


Go to testing and access the application.


image


CAT TOOL GUI


image


We can use this “Analyze Conflict” , Generate Report etc.


image








Click analyze conflict. It showed me conflicting classes and gave me suggested solution that I can use in my weblogic-application.xml or weblogic.xml.


image