Unable To Open Webviewable File When Using Custom Metadata Field in File Store Provider Weblayout Path (Doc ID 1350507.1)

Last updated on MAY 10, 2017

Applies to:

Oracle WebCenter Content - Version 11.1.1.3.0 and later
Information in this document applies to any platform.

Symptoms

In WebCenter Content (WCC) (formerly Universal Content Management or UCM), using a FileStoreProvider (FSP) storage rule that adds a custom metadata field to the vault and weblayout paths works fine for the vault directory, but fails for the weblayout directory.  The indexer fails to rename the weblayout file, which means that the file name in the weblayout directory contains a ~1 after checkin.   This causes the webviewable URLs not to work.

To reproduce the issue:

  1. Create a custom metadata field; for this example, the field created is named StorageTier.  Make it a text field with an option list with a single value; for this example, the value in the option list is named tier1.
  2. Create a new FSP storage rule using this custom metadata field in the paths as follows:

    Vault Path
    $#env.VaultDir$$xStorageTier$/$dDocType$/$dDocAccount$/$dispersion$/$dID$$ExtensionSeparator$$dExtension$

    Weblayout Directory [$FsWeblayoutDir$ in Web-viewable Path]
    $#env.WeblayoutDir$$xStorageTier$/

    Dispersion Rule [$dispersion$ in Web-viewable and vault path]
    (Keep at default): $dRevClassID[-9:-6:0:b]/$dRevClassID[-6:-3:0:b]

    Web-viewable Path
    (Keep at default): $FsWeblayoutDir$groups/$dSecurityGroup$/$dDocAccount$/documents/$dDocType$/$dispersion$/~edisp/$dDocName$$RenditionSpecifier$$RevisionLabel$$ExtensionSeparator$$dWebExtension$

    HttpWebRoot and URL Prefix [$fsHttpWebRoot$ in Web URL File Path]
    $HttpWebRoot$$xStorageTier$/

    Web URL File Path
    (Keep at default): $FsHttpWebRoot$groups/$dSecurityGroup$/$dDocAccount$/documents/$dDocType$/$dispersion$/~edisp/$dDocName$$RenditionSpecifier$$RevisionLabel$$ExtensionSeparator$$dWebExtension$

  3. Check in a content item.  On the Checkin page, select the storage rule you created and select the value of tier1 for the xStorageTier field.
  4. After the content item is released, look at the files in the weblayout directory and notice that the file still has a ~1 which causes webviewable URLs not to work.
  5. If you turn on indexer tracing from the System Audit Information page, you will see these errors in the trace output when clicking on the webviewable URL:
>indexer/6 03.31 11:26:34.907 index update work !syFileUtilsTargetFileNoAccess!syFileUtilsUnableToRenameFile,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout/tier2/groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000005~1.txt,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout//groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000005.txt exception stack
indexer/6 03.31 11:26:34.907 index update work intradoc.common.ServiceException: !syFileUtilsTargetFileNoAccess!syFileUtilsUnableToRenameFile,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout/tier2/groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000005~1.txt,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout//groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000005.txt
indexer/6 03.31 11:26:34.907 index update work at intradoc.common.FileUtils.renameFileEx(FileUtils.java:1661)
indexer/6 03.31 11:26:34.907 index update work at intradoc.filestore.filesystem.FileSystemEventImplementor.renameOnEvent(FileSystemEventImplementor.java:234)
indexer/6 03.31 11:26:34.907 index update work at intradoc.filestore.filesystem.FileSystemEventImplementor.notifyOfEvent(FileSystemEventImplementor.java:71)
indexer/6 03.31 11:26:34.907 index update work at intradoc.filestore.BaseFileStore.notifyOfEvent(BaseFileStore.java:775)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.CommonIndexerBulkLoader.notifyOfRelease(CommonIndexerBulkLoader.java:463)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.CommonIndexerBulkLoader.loadRecordWebChange(CommonIndexerBulkLoader.java:235)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.IndexerBulkLoader.createBulkLoad(IndexerBulkLoader.java:321)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.IndexerBulkLoader.doWork(IndexerBulkLoader.java:170)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.Indexer.doIndexing(Indexer.java:411)
indexer/6 03.31 11:26:34.907 index update work at intradoc.indexer.Indexer.buildIndex(Indexer.java:319)
indexer/6 03.31 11:26:34.907 index update work at intradoc.server.IndexerMonitor.doIndexing(IndexerMonitor.java:1021)
indexer/6 03.31 11:26:34.907 index update work at intradoc.server.IndexerMonitor$4.run(IndexerMonitor.java:841)



If FsIsCopyDeleteOnRename=true is set, the same problem occurs, but the error is a little different:

>indexer/6 03.31 11:35:58.267 index update work !syGeneralError exception stack
indexer/6 03.31 11:35:58.267 index update work intradoc.common.ServiceException: !syGeneralError
indexer/6 03.31 11:35:58.267 index update work at intradoc.common.FileUtils.renameFileEx(FileUtils.java:1638)
indexer/6 03.31 11:35:58.267 index update work at intradoc.filestore.filesystem.FileSystemEventImplementor.renameOnEvent(FileSystemEventImplementor.java:234)
indexer/6 03.31 11:35:58.267 index update work at intradoc.filestore.filesystem.FileSystemEventImplementor.notifyOfEvent(FileSystemEventImplementor.java:71)
indexer/6 03.31 11:35:58.267 index update work at intradoc.filestore.BaseFileStore.notifyOfEvent(BaseFileStore.java:775)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.CommonIndexerBulkLoader.notifyOfRelease(CommonIndexerBulkLoader.java:463)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.CommonIndexerBulkLoader.loadRecordWebChange(CommonIndexerBulkLoader.java:235)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.IndexerBulkLoader.createBulkLoad(IndexerBulkLoader.java:321)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.IndexerBulkLoader.doWork(IndexerBulkLoader.java:170)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.Indexer.doIndexing(Indexer.java:411)
indexer/6 03.31 11:35:58.267 index update work at intradoc.indexer.Indexer.buildIndex(Indexer.java:319)
indexer/6 03.31 11:35:58.267 index update work at intradoc.server.IndexerMonitor.doIndexing(IndexerMonitor.java:1021)
indexer/6 03.31 11:35:58.267 index update work at intradoc.server.IndexerMonitor$4.run(IndexerMonitor.java:841)
indexer/6 03.31 11:35:58.267 index update work Caused by: intradoc.common.ServiceException: !syFileUtilsUnableToCopy,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout/tier2/groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000006~1.txt,/apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout//groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000006.txt
indexer/6 03.31 11:35:58.267 index update work at intradoc.common.FileUtils.copyFileEx(FileUtils.java:1753)
indexer/6 03.31 11:35:58.267 index update work at intradoc.common.FileUtils.copyFile(FileUtils.java:1692)
indexer/6 03.31 11:35:58.267 index update work at intradoc.common.FileUtils.renameFileEx(FileUtils.java:1602)
indexer/6 03.31 11:35:58.267 index update work ... 11 more
indexer/6 03.31 11:35:58.267 index update work Caused by: java.io.FileNotFoundException: /apps/middleware/user_projects/domains/ecm1_domain/ucm/cs/weblayout/groups/public/documents/document/mdaw/mdaw/~edisp/ucm11g1_000006.txt (No such file or directory)
indexer/6 03.31 11:35:58.267 index update work at java.io.FileOutputStream.open(Native Method)
indexer/6 03.31 11:35:58.267 index update work at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
indexer/6 03.31 11:35:58.267 index update work at java.io.FileOutputStream.<init>(FileOutputStream.java:70)
indexer/6 03.31 11:35:58.267 index update work at intradoc.common.FileUtils.copyFileEx(FileUtils.java:1740)
indexer/6 03.31 11:35:58.267 index update work ... 13 more

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms