Tuesday, January 3, 2012

Increase maximum number of folders and content per folder

Changing maximum content and folders per folder to be more than 1000 gives an error in UCM 11g.

It is not recommended to increase number of folders where user may got out of memory. The limitation comes from Java Runtime Environment. However sometimes you need to increase it a little.

The following steps explain how to increase it from 1000 to 2000.
- Browse to Oracle UCM configurations directory (for example /u01/oracle/ecm1/ucm)
- Then move to folders component configurations directory /cs/data/components/folders
- You will find a file called config.cfg
- Change the following parameters
MaxContent=2000
MaxFolders=2000
- Restart UCM and test


Wednesday, November 16, 2011

Modify UCM Workflow History

If you want to generate reports on Workflow, you may noticed two tables in UCM schema called DocumentHistory and WorkflowHistory. Both of them audits and saves all actions  done.

But those tables have few fields, notice DocumentHistory table
What if we want to add new fields to to the history, why? because I want to track changes on some custom fields and report them, another example if I want to track updates done on metadata fields using "Update" action.

Good news UCM is great, we can add our custom fields to the table (simply by modifying table structure), like adding xComments

At the end we can overwrite UCM query that inserts to the table actions' history. So we will modify IdocHistory, as the following

<tr> <td>IdocHistory</td> <td>INSERT INTO DocumentHistory (dActionMillis, dActionDate, dID, dRevClassID, dUser, dDocName, dAction, dSecurityGroup, xComments) values(?, ?, ?, ?, ?, ?, ?, ?, ?)</td> <td>dActionMillis int dActionDate date dID int dRevClassID int dUser varchar dDocName varchar dAction varchar dSecurityGroup varchar xComments varchar</td> </tr>

Tuesday, November 8, 2011

Senior Oracle ECM Consultants required for ME

I have several openings for Oracle ECM consultants, the openings are with a couple of companies. The required resources should have good experience with Oracle ECM for three years at least, and preferable to be based on Saudi Arabia (Having Visa there is a big plus), Jordan, Egypt, and Kuwait.

Send to me you resume, so that I will forward it to the companies. My email is hisham.galal.eldin@gmail.com (note most likely I am not the interviewer, I am just broker :) ).

If you are talented fresh graduate (I mean you have done something interesting) either your experience in ECM or other FMW products, send your resume too you are most welcomed.


Saturday, October 22, 2011

Modify Workflow Popup

Recently I got requirement to modify workflow popup menu according to certain conditions

The following explains how simply to do that:

  • Go to the following directory <middleware_home>/Oracle_ECM1/ucm/idc/resources/core/idoc
  • In that directory, we have two interesting files that contains most of resource includes that we desire to customize std_page.idocstd_workflow.idoc
  • As per our requirement of customizing Workflow related feature so our target will be std_workflow.idoc, inside it you will find an include called setup_workflow_action_popups
  • I will assume you will be able to create a new component, and add a resource file to it, then inside that resource file copy and past the include setup_workflow_action_popups from std_workflow.idoc as is.
  • Now lets take a look at the include
You will find there repeating parts in the include everyone is representing an item in the popup menu.


<$exec rsAppendNewRow("PopupProps")$>

<$exec setValue("PopupProps", "label", lc(""))$>

<$exec setValue("PopupProps", "function", "")$>
<$exec setValue("PopupProps", "ifClause", "")$>

<$exec setValue("PopupProps", "class", "workflow")$>
<$exec setValue("PopupProps", "id", "")$>

id: unique i for the popup menu item
class: will be always workflow
function: either a link location or javascript calls. The link may be composited by idoc script
label: localized display label for the popup menu item
ifClause: Which is the amazing feature, it is the condition for displaying the menu item and it can be something like dDocType like 'Correspondence' and of course you can make use of the existing conditions like AllowReviewAllowCheckin 

Here is an example of a new item I added


<$exec rsAppendNewRow("PopupProps")$>

<$exec setValue("PopupProps", "label", lc("wwUpdateAndApprove"))$>

<$exec setValue("PopupProps", "function", "<$HttpCgiPath$&>IdcService=GET_UPDATE_FORM&dDocType=Correspondence&dID=<$dID$>&dDocName=<$url(dDocName)$>&idcToken=<$idcToken$>")$>
<$exec setValue("PopupProps", "ifClause", "dDocType like 'Correspondence'")$>
<$exec setValue("PopupProps", "class", "workflow")$>
<$exec setValue("PopupProps", "id", "workflowUpdateAndApprove")$>

The two resource file std_page.idoc & std_workflow.idoc will make you very powerful, don't miss them and don't give up until you find your needs.


Thursday, October 6, 2011

Oracle Public Cloud

Did you see this website before cloud.oracle.com?


The interesting part for me is building your custom business application over Oracle Public Cloud, which will be stable and easy to configure and highly available. Customers in Middle East will take time to accept Public Cloud over building their own Private Cloud which is a correct decision for specific decisions.

May be hosting Website built using web content s or some kind of portals there will be applicable.

Friday, September 16, 2011

Solved password reset for UCM 11g

Today I returned to the password reset issue in UCM 11g, and I solved it by creating a custom component. Just less than 27 line of code solved it !!! till now I wonder why Oracle missed that.

Anyway I want to share it with you in case you faced the same problem and you were looking for a solution.

I will assume you know how to create a custom service, and in case if you don't know refer to The Definitive Guide to Stellent Oracle Content Server for Bex Huff.

1- Create a custom component using Component Wizard

2- Create a java class and make this class extends UserService

3- Add the following method to the class


public void resetPassword() throws Exception {
      Hashtable env = new Hashtable();
      env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
      env.put(Context.PROVIDER_URL, "ldap://localhost:7001/dc=my_domain");
      env.put(Context.SECURITY_AUTHENTICATION, "simple");
      env.put(Context.SECURITY_PRINCIPAL, "cn=Admin");
      env.put(Context.SECURITY_CREDENTIALS, "weblogic1");
      DirContext ctx = new InitialDirContext(env);
      ModificationItem[] mods = new ModificationItem[1];
      Attribute mod0 = new BasicAttribute("userpassword", m_binder.getLocal("dPassword"));
      mods[0] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE, mod0);
      ctx.modifyAttributes("uid=sysadmin,ou=people,ou=myrealm", mods);
}

3- Modify the existing service EDIT_USER_PROFILE (by the Component Wizard)
-Change service class to the newly created class by you (don't forget package name)
-Then add new action which is of type java method and refers to our newly created method resetPassword
-Order actions so that resetPassword be before storeUserDatabaseProfileData

At the end restart and test. One last thing from inside weblogic administration console, you need to change embedded ldap credential and be sure it is configured correctly.