Monday, September 17, 2012

Top Five Clustering Guidelines for ADF


I found following five guidelines very useful as per my experience:-

1. All the beans stored in session scope, page flow scope, and view scope need to be serialized. We can serialize backingBean scope as well if any value is changing from the UI.

2. All the referenced member objects in the serialized class should implement Serializable interface.

3. It is strongly recommended that all serializable classes explicitly generate default serialVersionUID value from the JDeveloper.

4. Do not use any non-serializable (for example XMLGregorianCalendar) data type in the serialize class.

5. If any object (UI components) is not serializable then it must be marked Transient

Sunday, August 19, 2012

How to add a favicon Image to the browser tab/URL in WebCenter?


Prerequisites:

1. WebCenter is installed 
2. OHS is installed and configured for WebCenter as a frontend HTTP Server

Steps

 To add the favicon image in your WebCenter application, follow the following steps:-
 
1. Go to following directory of Oracle HTTP Server (OHS)  

/oracle/middleware/Oracle_WT1/instances/instance1/config/OHS/ohs1/htdocs/

2. Add favicon.icon image (size : most commonly 16×16 pixels) in above folder 
3. Restart the OHS 

It will show in the browser tabs/URL when you browse to WebCenter.

For favicon support and limitation in different browser, see http://en.wikipedia.org/wiki/Favicon

Sunday, July 29, 2012

How to resolve 8dot3 semantics issue when adding content from Desktop Integration Suite (DIS) or UCM console into Content Server


 On Content server browser window, you will get following alert:-

"The weblayout directory is on a filesystem with 8dot3 semantics. Legacy 16-bit 8dot3 filenames conflict with revision labels and will cause file loss. Disable 8dot3 semantics by running Installer DisableNtfs8dot3 and then restarting Windows."


When you try to add contents to DIS window or trying adding contents from UCM taskflows of WebCenter Spaces , you will get following error in case of DIS:-

And you will get following error in case of UCM taskflows (like document explorer, folder viewer etc) from WebCenter Spaces:-

You cannot upload document. Permission denied.

Quick Solution

 And you will not able to add contents. To resolve this issue, go to following registry location:-
HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/FileSystem
 
 

Then, change the value  of the NtfsDisable8dot3NameCreation key to 1. You must restart Windows for the new setting to take effect.

Please note that the solution has been tested on Windows7 only.

Sunday, July 8, 2012

How to increase maximum uploading size for UCM taskflows from WebCenter Spaces?



When try to upload file more than 2MB from UCM taskflows into WebCenter Spaces, you will get following error:-

The file could not be uploaded because it is too large. Enter the file name and location. Files must be less than 2 GB

According to PS3/PS4 documentation, its limit is 2MB not 2GB as error message misleading you.

How to increase the upload limit

1.     Export webcenter-config.xml file using following command:-

wls:/wc_domain/serverConfig> exportMetadata(application='webcenter', server='WC_
Spaces', toLocation='/tmp/', docs='/oracle/webcenter/webcenterapp/metadata/webce
nter-config.xml')

Executing operation: exportMetadata.

Operation "exportMetadata" completed. Summary of "exportMetadata" operation is:
List of documents successfully transferred:

/oracle/webcenter/webcenterapp/metadata/mdssys/cust/site/webcenter/webcenter-con
fig.xml.xml
/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml

2 documents successfully transferred.

2. Open the webcenter-config.xml file in text editor in order to modify file upload size:-.
<webcenter:uploadedFileMaxDiskSpace>2097152</webcenter:uploadedFileMaxDiskSpace>

Please note that the size is in bytes.


3. Once updated, run the following import command:-

wls:/wc_domain/serverConfig> importMetadata(application='webcenter', server='WC_
Spaces', fromLocation='/tmp/', docs='/oracle/webcenter/webcenterapp/metadata/web
center-config.xml')

Executing operation: importMetadata.

Operation "importMetadata" completed. Summary of "importMetadata" operation is:
List of documents successfully transferred:

/oracle/webcenter/webcenterapp/metadata/mdssys/cust/site/webcenter/webcenter-con
fig.xml.xml
/oracle/webcenter/webcenterapp/metadata/webcenter-config.xml

2 documents successfully transferred.

It works without restarting any Managed Server.

Sunday, May 6, 2012

How to change HTTP Session Timeout for WebCenter Spaces?


 If you see WebCenter Spaces application (webcenter.ear) session-timout from the Weblogic Console, this session Timeout (3600 Seconds) is misleading and not applicable in case of WebCenter Spaces application. If you update this value from the console, it will not impact session-timeout of the WebCenter Spaces application.
 
Then question is how can I change session-timeout for WebCenter Spaces application? By default session-timeout set in web.xml is 45 minutes. There are following two ways to change the session-timeout:-
  
        1. Deployment Descriptors(web.xml and weblogic.xml)
       2. Customizing the Session Timeout sample project of SampleWebCenterSpacesExtensions (Supported solution till PS4)

Here, we will not discuss solution-2 as this project is excluded from PS5 documentation and sample project. If you are running WC Spaces PS3 or PS4, you can implement it as well.

You can update the session timeout in web.xml as well as weblogic.xml but if web.xml takes precedence over the weblogic.xml. Here, we will configure the session timeout in web.xml as recommended by Oracle in following documentation as well:-


Following are the steps to modify the web.xml for session timeout value:-

1.       Go to <WEBCENTER-HOME> /archives/applications directory and you will find webcenter.ear file there. In my case the complete path is C:\Oracle\Middleware\Oracle_WC1\archives\applications.
2.       Backed up webcenter.ear in <WEBCENTER-HOME> /archives/applications as webcenter.ear.bak
3.       Open the webcenter.ear file using winrar or 7zip or any other tool

4.       Now, go to spaces.war >> WEB-INF folder and open the web.xml file in editor
 
     

5.       Add following entry in it:-
<session-config>
                                         <session-timeout>15</session-timeout>
                         </session-config>
Pls note that session-timeout value in web.xml is in minutes whereas in weblogic.xml it is in seconds.


6.       Once done, save it and close it.
7.       Make sure that webcenter.ear contain an updated web.xml.
8.       Restart WC_Spaces servers. At startup, this automatically deploys the newer application with the modified web.xml.
Note: Once application is deployed, revised spaces.war is available at <DOMAIN-HOME> /servers\WC_Spaces\tmp\_WL_user\webcenter_11.1.1.4.0\<Randon-Folder-Name>. You can verify the web.xml changes as well.


Note:- From PS5 onward, there is one more way to change the session timeout, see the following documentation:-
http://docs.oracle.com/cd/E23943_01/webcenter.1111/e12405/wcadm_gen_prop.htm#BCEHFHCH


References:-