4-54 Oracle Fusion Middleware System Administrators Guide for Oracle Content Server
IsWritable vault
env.VaultDirdDocTypedDocAccountdispersiondIDExtensionSeparator dExtension
6 true
default weburl
HttpCgiPath?IdcService=GET_FILEdID=dRevClassID
dDocName=dDocNameallowInterrupt=1noSaveAs=1fileName=dOriginalName 3
false default
weburl.file FsHttpWebRootgroupsdSecurityGroupdDocAccountdocumentsdDocType
dispersion~edispdDocNameRenditionSpecifierRevisionLabel ExtensionSeparatordWebExtension
3 false
default web
FsWeblayoutDirgroupsdSecurityGroupdDocAccountdocumentsdDocType
dispersion~edispdDocNameRenditionSpecifierRevisionLabel ExtensionSeparatordWebExtension
3 true
default end
4.3.5.4 Configuration for Database Storage
To store files in the database, you need a storage rule that is of type JdbcStorage. By default, all content items belonging to this rule have their files stored in the database.
However, even though the files are stored in the database, there is the presumption of an underlying file system and the system may need to temporarily cache a file on the
file system. In particular, this may happen for indexing or for some conversions.
4.3.5.4.1 Defining the Storage Rule In the default rule below, all files are stored in the
database, while the filesInWeb rule stores the vault files in the database and the web files on the file system.
ResultSet StorageRules 4
StorageRule StorageType
IsWeblessStore RenditionsOnFileSystem
default JdbcStorage
filesInWeb JdbcStorage
web end
Tech Tip: A rule can be configured to always store renditions
belonging to a given storage class on the file system. This is most useful for systems that store vault files in the database, but web files
on the file system.
Managing System Settings 4-55
4.3.5.4.2 Defining the Path Construction ResultSet PathConstruction
4 FileStore
PathExpression AutoCreateLimit
IsWritable StorageRule
vault env.VaultDirdDocTypedDocAccountdispersiondIDExtensionSeparator
dExtension 6
true default
weburl.file FsHttpWebRootgroupsdSecurityGroupdDocAccountdocumentsdDocType
dispersion~edispdDocNameRenditionSpecifierRevisionLabel ExtensionSeparatordWebExtension
3 false
default web
FsWeblayoutDirgroupsdSecurityGroupdDocAccountdocumentsdDocType
dispersion~edispdDocNameRevisionLabelRenditionSpecifier ExtensionSeparatordWebExtension
3 true
default end
4.3.5.5 Altered Path Construction and Algorithms
The previous examples have kept the file paths consistent with the standard configuration. For very large implementations, this can result in directory saturation
and slow performance. The following examples aid in dispersing files over several storage options.
4.3.5.5.1 Using Partitioning FileStoreProvider makes it easy to use partitions to create a
sparser directory structure. By default, the xPartitionId metadata field is used and becomes a part of a content item revisions metadata information. It is recommended
that this field is disabled on the Oracle Content Server user interface, instead letting the partition selection algorithm determine the partition to use. The partition selection
algorithm looks at all the active partitions, and as a new content enters the system, the partitions are selected in order. Each partition has an entry in the
PartitionList Table and can be declared active. The PartitionRoot is calculated from xPartitionId,
where the value is a look up key into the PartitionList table. If no xPartitionId is specified, the system finds the next available and active partition and uses this value
for the location calculation. The xPartitionId is then stored as part of the content items metadata.
To use the partition selection, define the vault storage class in the PathConstruction table as follows:
vault PartitionRootdDocTypedDocAccountdRevClassIDExtensionSeparatordExtens
ion 6
true
4-56 Oracle Fusion Middleware System Administrators Guide for Oracle Content Server
Partitions can be deactivated using the AddEdit Partition Page
at any time if a system administrator needs to close a partition to contribution, for example if
maintenance is required on the storage device.
4.3.5.5.2 Adding a Partition to the Weblayout Path This example shows how to partition
both vault and weblayout directories, and also maintain valid web URL file paths. Add the partition root to the web-viewable path and web URL file path, and edit the
variables FsWeblayoutDir and FsHttpWebRoot on the Storage Rule Name
Dialog .
FsWeblayoutDir represents PartitionRootweblayout. FsHttpWebRoot represents HttpWebRootxPartitionIdweblayout.
Define partitionRoot in the AddEdit Partition Page
as follows:
In order to keep the web URL file path consistent with the web-viewable path in the weblayout directory, the variable xPartitionId is used so that partition1 or
partition2 is correctly replaced when creating the web URL file path.
Ensure that the web-viewable path and the web URL file path evaluate into the same path.
■
FsWeblayoutDir represents PartitionRootweblayout. For partition1 this evaluates to
env.WeblayoutDirpartition1weblayout. For partition2 this evaluates to env.WeblayoutDirpartition2weblayout.
■
FsHttpWebRoot represents HttpWebRootxPartitionIdweblayout. For partition1 this
evaluates to HttpWebRootpartition1weblayout. For partition2 this evaluates to HttpWebRootpartition2weblayout.
If you set up the partitions partition1 and partition2 to use the partition root of env.VaultDirpartition1 and env.VaultDirpartition2 instead
of the env.WeblayoutDir and HttpWebRoot settings, then the weblayout file will end up stored in the vault directory. It then can be used only for partitioning
the vault files.
4.3.5.5.3 Limiting the Number Files in a Directory Another way of dispersing files is to
alter the path so that files get partitioned out by the dRevClassID of the content item. In the example below, the directories are limited to 10,000 files plus extra files for
additional renditions.
If your path expression contains RevClassID[-12:-10:0]dRevClassID[-10:-8:0]dRevClassID[-8:-
4:0] and dRevClassID is 1234567890, the result is 00123456.
Note the dRevClassID[-12:-10:0] in the path expression. This is interpreted as follows:
■
Get the characters starting at 12 back from the end of the string until you get the character 10 back from the end of the string.
■
Pad the resulting string to length 2, which 12-10, with 0 characters.
Partition Name Partition Root
partition1 env.WeblayoutDirpartition1
partition2 env.WeblayoutDirpartition2
Managing System Settings 4-57
4.4 Mapping URLs with WebUrlMapPlugin
An Oracle Content Server system uses an Oracle WebLogic server, which has a built-in web server, to filter pages through a web browser. User requests are authenticated
with the Oracle WebLogic server user store and communicated with the Oracle Content Server system.
The WebUrlMapPlugin component enables you to map shortened URLs to other URLs in g] using a substitution script for the mapping, which also enables you to map long
URLs to abbreviated versions. The WebUrlMapPlugin component is installed enabled by default with the Oracle Content Server instance.
This section covers these topics:
■
Section 4.4.1, Script Construction
■
Section 4.4.2, Supported Variables for Referencing
■
Section 4.4.3, AddEdit URL Mapping Entries
■
Section 4.4.4, Mapping Examples
4.4.1 Script Construction
The shortened URLs that you can create generally use the following format: http:myhostname.comprefixsuffix
The actual mapping process is based on the part of the URL that follows the host name portion. To resolve the shortened URL, the Oracle Content Server instance compares
the prefix to those in the list of defined WebUrlMapPlugin entries. If a match exists, the Oracle Content Server instance uses the map script that corresponds to the
matching prefix to display the applicable document or Oracle Content Server page. For more information about the suffix, see
Section 4.4.2, Supported Variables for Referencing.
To construct a URL mapping entry using the WebUrlMaps Screen
, you must establish a prefix and define the corresponding map.
■
Prefix The prefix portion of the mapping entry is any abbreviation you want to use to
identify URLs of a certain form. For example, if you want your short URL to return the dynamic conversions of documents, you can use idc as your prefix for
example, the abbreviated form of dynamic converter.
When you create your prefix, do not enter a slash character at the beginning of it because the Oracle Content Server instance removes the first slash from the
incoming URL before the prefix test is performed.
■
Map The map portion of the mapping entry is the Idoc Script code that the Oracle
Content Server instance uses to resolve the shortened URL. You can use substitution tags --variable-- in the map portion. Examples include:
– --cgipath--
Caution: Include a slash at the end of your URL map prefix.
Otherwise, your mappings can apply to many more URLs and interfere with standard Oracle Content Server operations.