Thursday, May 6, 2010

com.documentum.ucf.common.UCFException

Error:
I am getting the error - com.documentum.ucf.common.UCFException, while tried to export the file from DA6.5
***************************************************************
Failed to retrieve content from ACS/BOCS server(s). The ACS/BOCS server(s) may be down or your machine may not be able to reach the server(s) due to network connectivity or configuration issues com.documentum.ucf.common.UCFException: All remote hosts failed
****************************************************************
Resolution:
ACS is a servlet on the Java Method Server and it is down. So check the Tomcat logs. If you don't use this then I would suggest disabling it.
TO disable - modify the setting app.xml in webtop:
As per my DA installtion on local, File path: C:\apache-tomcat-6.0.18\webapps\da\wdk
Please disable it in both - accelerated-read & accelerated-write, by modifing the tag enabled to false.

Facing issue while exporting a file through DFC in D6.5

Error Description:
When I tried to export a file through code-
doExport("/Temp/test1/test_doc","C:\\AMIT_VERMA\\New Folder\\","test_doc","Excel 2007 Workbook",dfSession);
I am getting the following error message:
**********************************************************************
java.lang.NullPointerException
at com.documentum.operations.DfOperation.getFileExtensionToUse(DfOperation.java:2026)
at com.documentum.operations.DfGetContentFile.getDefaultOutputFile(DfGetContentFile.java:91)
at com.documentum.operations.DfGetContentFile.getContentFile(DfGetContentFile.java:848)
at com.documentum.operations.DfGetContentFile.execute(DfGetContentFile.java:61)
at com.documentum.operations.DfOperationStep.execute(DfOperationStep.java:135)
at com.documentum.operations.DfOperation.execute(DfOperation.java:432)
at ExportDoc.doExport(ExportDoc.java:230)exception is:null
**********************************************************************
Method Code:
public static void doExport( String strPath, String destDir,
String exportName, String exportFormat, IDfSession session )
throws DfException {
IDfClientX clientx = new DfClientX();
IDfSysObject sysObj = (IDfSysObject) session.getObjectByPath( strPath );
if( sysObj == null ) {
System.out.println("Object " + strPath + " can not be found.");
return;
}
else{
System.out.println("Object " + strPath + " has been found.");
}
sysObj.setObjectName(exportName);
System.out.println("export name is " + exportName);
IDfExportOperation operation = clientx.getExportOperation();
operation.setDestinationDirectory( destDir );
System.out.println("destDir name is " + destDir);
IDfExportNode node = (IDfExportNode)operation.add( sysObj );
node.setFormat( exportFormat );
System.out.println("exportFormat name is " + exportFormat);
operation.execute();
System.out.println( "exported file path: " + node.getFilePath() );
}

*************************************************************************
Resolution:
I have successfully called the method with slight correction of export format -
doExport("/Temp/test1/test_doc","C:\\AMIT_VERMA\\New Folder","test_doc","excel12book",dfSession);
***************************************************************************
You can get more details format's name for each file type by -
Documentum Administrator -> Formats

It displays the format's name and description. The DOS extension is not showed, but you can see it on it's Info page.
Or you run a query like this:
SELECT name, dos_extension FROM dm_format WHERE dos_extension='docx'