Archive

Archive for December, 2010

Creation of Workflows in Documentum using Workflow Manager

December 3, 2010 Comments off

Workflow is the automation of a business procedure, during which it specifies how content (document, information or tasks) is routed for review/approval from one participant to other, before it is released to the system. Users are notified by e-mail when they have some content to review.

Role of Workflows in business:

Workflows help to streamline the business process.Reduced time, fewer mistakes and improved quality of work. Information about the task readily available at any point of time.

Uses:

  1. Improved change management.
  2. Improved services and management.
  3. Inter-Organization communications.
  4. Reduces operating costs.
  5. Improved productivity by automating routine and repetitive tasks.

Every workflow has a number of logical steps. This is called as an Activity. An Activity could involve manual interaction or can use machine resources. Activity involving manual interaction is called as a Manual activity. Manual activity has a performer. Activity which doesn’t require manual intervention is called as an Auto activity. It’s performed using machine resources.

Flows are the connectors. They connect the activities. They also specify the sequence of activities. Workflows may be parallel or serial. In serial workflow, tasks follow one after another in a sequence. In parallel workflow, two or more activities can happen concurrently.

Steps to create a workflow:

Once the business process is known, before creating the workflow, answer these questions for a better workflow design.

(Plan the workflow using the following points)

1.    Who initiates the workflow?

§  The person going to initiate or start the workflow should have ‘relate permission’ on the workflow template to start the workflow.

2.    Decide which activities are going to be manual activities and which are auto activities

§  Whether activities will be performed in serial or parallel

3.    Who is going to perform the manual activities?

§  Whether its going to be a specific user, a group, or some number of performers from a group will be included in the decision making process,

§  Whether the performers will be chosen at runtime or will the performer name be hard coded in the workflow template.

4.    When does an activity start?

§  When an activity has more than one incoming flow, you can specify how many activities should complete before this activity begins. This is the trigger for an activity.

5.    What are the activities that happen next?

§  How is the next activity chosen?  Whether the performer chooses the next activity, or all the activities connected to this one is chosen, or the next activity can be chosen based on some conditions.

6.    What documents are passed along the activities?

Some documents will be passes along these activities, on which some actions are performed. Packages can be added, through flow inspector connecting the two activities.

Given below is a sample workflow.

This workflow depicts a scenario of bank, wherein the concerned department receives application for loans, the loan papers are sent for review to the manager who then decides whether to grant the loan.

Now, let’s answer these questions for the above scenario.

1. Who initiates the workflow? – The clerk who receives the loan application from the customers. He/She should be given relate permission on the workflow. When a new loan application is received and it needs an approval from the manager, the clerk applies a workflow on the loan application.

2.    Decide which are going to be manual activities and auto activities:

Manual activities include a task where in the manager approves or rejects the loan. Auto Activity will include the business logic when the loan is rejected or approved.
We can call the Review activity by the manager as a manual activity.

3.    Who is going to perform the manual activity? – The performer has to be decided. Manager would be the performer. Instead of hard coding the manager id in the performer name, the performer could be chosen at runtime by the initiator. (This makes the workflow template more reusable.)

4.    What will trigger an activity in the workflow? – The next activity depends in the action taken by the performer. If approved, ‘Approve Loan’ activity will be triggered, else if rejected, ‘Reject Loan’ activity would be triggered.

5.    What documents are passed along the activities? – The documents passed along the activities in this case could be the loan papers, and other documents required in the process of Loan sanction.

This is the workflow template for the above given scenario.

‘Review’ is a manual activity.  (The option, the activity’s work is performed: By one more manual performers is chosen)

To select the performer, click on the select performer tab.

While selecting performers, Select option ‘some users from a group’, if there are many managers who review the document. Or select ‘single user from a group’, if the task will be sent to only one manager for review.

The Option ‘Multiple sequential performers’ will send tasks to the reviewers in serial fashion.

To choose the reviewer at runtime, select the option, ‘Have performer(s) of activity <Choose the activity here> determine performer(s) of this activity’.

Transition tab is to specify which activities should be started next. The option ‘Let the activity’s performer choose’

If there are three reviewers, and if the task is sent in parallel, and two of the three reviewers approve, and one reviewer rejects the loan, then we can chose either reject activity as the next activity, or approve activity as the next activity, as per the requirement.

Reject Loan is an auto activity. When a loan is rejected, the business logic is written in a java class, and that java class will be specified in the section, Execute this method automatically.

To get a method in this dropdown, create a method in DocApp, select option use as workflow method. To set up a java method as a workflow method, click here

Auto activity is executed using some permission. There are 4 options to choose from. The auto activity will execute depending on these permissions.

Review complete activity is another manual activity, which notifies the workflow supervisor that the workflow is complete. Again this activity solely depends on the requirement.

Flow inspector is used to pass the necessary documents between two activities.

To add a document, click on ‘Add New package’ and enter respective name and package type to be routed through the activities.

To set up a new JAVA method to run as an automatic Workflow method:

Create a method using DocApp with the following attributes.

Name: Method Name

Command: <classpath> or <classname>

Place the resultant class file where the Java run time on the Content Server machine can find it.

E.g.: 1) package.com.cs.server.classname- the class file should be present in the package.

2) Classname- the class file should be present in \dba\java_methods.

 

Run synchronously: True

(Time out in seconds)

Minimum: 60

Default: 100

Maximum: 300

Run as Server: True.

Trace launch: True

Use Method Server: True

Launch directly: False.

Use as workflow method: True.

You must check the option ‘Use as workflow method’ to make this method available for use in workflow templates. When “Use as workflow method” is set to “True”, the attribute “a_special_app” will be set to workflow. In order to have a custom method available for use in an Activity in Workflow Manager, the attribute, ‘a_special_app’ must be set to workflow.

Setting “Trace launch” to “True” in the method attributes will allow you to see this debug information printed to the server log, log4j.log. This can be used for debugging purposes.

 

Now, the created .class file should be placed in any of these two locations. As specified in command attribute of DocApp method.

1.       package.com.cs.server.classname – the class files should be present in the given hierarchy.

2.       The class file should be present in <DM_HOME>\dba\java_methods

The java class file should contain “acquire()” and “complete()” methods for it to run as an Automatic workflow method.

acquire(): Acquires a work item for the current user.

Work items are tasks in the workflow. After a work item appears in a performer’s inbox, the performer must acquire the work item before beginning work on the item. The user issuing this method must be the work item’s performer, the workflow supervisor, or a user with Sysadmin or Superuser privileges.

Executing this methods changes information in the queue item associated with the work item

complete(): Marks a work item as finished.

The user issuing this method must be the work item’s performer, the workflow supervisor, or a user with Sysadmin or Superuser privileges. The work item must be in the acquired state. If the method is successful, it sets the work item’s state to finished. Executing this method changes information in the queue item associated with the work item

// custom code needs to be added.

Steps to set up a custom workflow method in docbasic:

Create a method in DocApp

Set the type to dmbasic.

In the command tab, give the path as: .\dmbasic

–f\Documentum\product\5.2\install\admin\ebs file> –e

E.g.: -fD:\Documentum\product\5.2\install\admin\Loan_Approval.ebs -eLoanApprove

Place the file in the following location: <DM_HOME>\Documentum\product\5.2\install\admin

ACL on Workflow templates:

The workflow templates created needs relate permission to be used.

This can be done through DA  by running this (DQL)query

 

Update dm_process object  Set acl_name = ‘ACL Name’ Where object_name=‘Workflow Name’;

This will allow the user to apply the workflow on a particular document.

Utilities for Easy Handling of Administrator Work in Documentum

December 1, 2010 Comments off

Apart from installation and setting up of documentum server and client
environment, there are many important tasks which needs to be handled by an  Administrator in order for smooth and proper functioning of the set up.

Some of the tasks are mentioned below:
1. Modifying the configurations of servers, docbroker.
2. Creating new Docbases.
3. Maintaining Docbases.
4. Configuring, starting and shutting down servers.
5. Changing session configuration.
6. Managing content storage areas and content files.
7. Managing users and groups.
8. Managing security.

Utilities for Easy Handling of Administrative Task:

1.dm_error utility
We encounter various content server errors with just with an error code
without much information about it. Documentum has defined all the errors
with an expanded statement of the error, possible causes of it and
prescribes possible solutions for the error. Utility should be executed in the
command prompt of the content server.
Syntax: dm_error <error_code>

2.PreLoad Utility
Administrator operations include activities called Dumping and Loading Docbase.Dump and Load operations can be used to do the following activities:
a. Move a Docbase to one location to another.
b. Duplicate a Docbase.
c. Duplicate or move some portion of the Docbase.
A dump operation creates a binary file of objects dumped from a Docbase. If a dumped object has associated content files, the content files are either
referenced by full path or included directly in the dump file. The load operation loads the objects and content files into another Docbase.
PreLoad utility can be run on a dump file created to tell what all objects that
should be created in the new Docbase before loading the dump file. Utility can also be used to create a DQL script that you can edit and then run to create the needed objects.
Syntax:
preload docbase [-Uusername] -Ppassword -dump_file filename [-
script_file name]
The docbase is the name of the Docbase into which you are loading the dump
file. Filename is the name of the dump file, and name defines a name for the
output DQL script. If you do not include a username, the current user is
assumed.
Note: This utility does not report all storage areas in the source Docbase, but
only those that have been copied into the dump file.

3.dmclean Utility
Every Docbase requires a scheduled clean up need to be performed by
administrator. One such clean up includes removing orphaned content files.
When users delete a document, or any object that has a content file associated with it, the system deletes the object and marks the content as an orphan. The system does not delete the actual content file. This must be done using the dmclean utility. Dmclean can be run using:

a. Documentum Administrator.
b. A DQL EXECUTE statement.
Syntax:
EXECUTE do_method
WITH method = ’dmclean’,
arguments = ’-no_content -no_note -no_wf_template’
c. An Apply method
Syntax:
apply,session,NULL,DO_METHOD,METHOD,S,dmclean, ARGUMENTS,S,’-no_content -no_note -no_wf_template’
d. From Content Server command prompt
dmclean -docbase_name docbase -init_file init_file_name
-no_content -no_note -no_wf_template
Where wheredocbase is the name of the Docbase and init_file_name
is the name of the server.ini start up file for the Docbase’s server.

4.dmfilescan Utility
This utility is used to scan the one or more storage area and find any content
files that do not have associated content objects. The utility scans for orphaned files which are over 24 hours old.
Running the utility using EXECUTE statement:
EXECUTE do_method WITH method = ’dmfilescan’,
[arguments = ’[-s storage_area_name] [,-from directory1]
[,-to directory2]’]
The utility automatically saves the output to a document that is stored in
the Temp cabinet. FALSE.) The output is a generated script that includes
the informational messages generated by the utility.
Running the utility using Content Server command prompt:
dmfilescan -docbase_name name -init_file init_file_name
[-s storage_area_name][-from directory1][-to directory2]
The init_file_name is the name of Content Server’s server.ini file. This is
one of the server start up files.

5.dm_crypto_change_passphrase Utility
Every installation of a Content Server creates a key called Administration
Encryption Key (AEK). This is used to encrypt:
a. The Docbase keys.
b. Documentum passwords, such as those used by Content Server to
connect to the RDMS or any other Docbase.
This AEK is stored at: %DOCUMENTUM%\dba\secure\aek.key and this key also are encrypted using a default passphrase provided by Documentum. It is always advisable to change the default passphrase. To change the default passphrase we can use dm_crypto_change_passphrase Utility.
Syntax:
dm_crypto_change_passphrase [-location location][-passphrase
[old_passphrase]][-newpassphrase [new_passphrase]][-noprompt][-help]
Location is the place where AEK is placed for which we need to change the
passphrase.
old_passphrase is the old passphrase name.
new_passphrase is the new passphrase name.
-noprompt should be used if any one the argument mentioned above is not
used. It’s like the end specify mentioning the end of arguments.
-help returns help information for the utility.

6.IAPI Utility
IAPI Utility is used to issue direct method call to the server.
Running the utility from the server command prompt:
iapi32 [-Uusername|-ENV_CONNECT_USER_NAME]
[-Pos_password|-ENV_CONNECT_PASSWORD] [-Llogfile] [-X][-E]
[-V-][-Q] docbase|-ENV_CONNECT_DOCBASE_NAME [-Rinputfile]
[-Ftrace_level][-Sinit_level][-Iescape_character][-zZ]
[-Winteger][-Ksecure_mode]
Order of the parameter does not hold importance.
Username- Identifies the name who is starting the session.
ENV_CONNECT_USER_NAME- User name in looked in the environment
variable DM_USER_NAME.
Password- User’s operating system password.
ENV_CONNECT_PASSWORD- Password is looked in the environment
variable DM_PASSWORD.
-Llogfile – Directs the server to start a log file for the session.
You must include the file name with the argument. You can specify a
full path.
-X Allows prompt for domain.
-E Turns on echo.
-V- Turns verbose mode off. The utility runs in verbose
mode by default. If you turn verbose mode off, the
system does not display the IAPI prompt, error
messages, or any responses to your commands
(return values or status messages).
-Q Directs the utility to provide a quick connection test. The utility attempts to connect and exits with a status of zero if successful or non-zero if not.
It provides error messages if the attempt is not successful.
Docbase- Docbase name which is intended to access.
ENV_CONNECT_DOCBASE_NAM – finds the name of the docbase
from environment variable DM_USER_NAME.
-Rinputfile input file with API methods.
-Ftrace_level Turns tracing on.
-Sinit_level Defines the connection level established when you
start the API session.

-Iescape_character Defines an escape character for certain symbols
such as a forward slash (/).
-zZ Specifies Windows NT Unified Logon.
7.IDQL Utility
IDQL is also a useful as a tool for testing and other tasks that support an
application or installation because it allows you to run scripts and batch files.
Running the utility from the server command prompt:
idql32 [-n] [-wcolumnwidth]
[-Uusername|-ENV_CONNECT_USER_NAME]
[-Pos_password|-ENV_CONNECT_PASSWORD][-Ddomain]
docbase|-ENV_CONNECT_DOCBASE_NAME [-Rinput_file]
[-X][-E][-Ltrace_level][-zZ][-Winteger][-Ksecure_mode]
The parameter being the same as mentioned in above utility.

%d bloggers like this: