Documentation Center

Storing items from different Publications in separate subfolders

If you use the deprecated in-process API, then by default, Content Delivery takes all items that you configured to be stored on the file system, and stores them in one file system location. If you want, you can override this default behavior and configure the Storage Layer to instead store items from different Publications in different subfolders. To achieve this, set the defaultFilesystem attribute to true in the Storage element of the file system storage item.

About this task

By default, all items that are published to the file system are placed in the one folder specified in the Path attribute of the Root child element of the Storage element representing file system storage.

Procedure

  1. Open the Storage Layer configuration file, cd_storage_conf.xml, which is located in the config\ subdirectory of your Content Delivery root location, for editing.
  2. Find the Storage element that represents file system storage.
  3. In this Storage element, set the defaultFilesystem attribute to true:
    <Storage Type="filesystem" Id="LocalFileSystem" defaultFilesystem="true"	Class="com.tridion.storage.filesystem.FSDAOFactory">
    	<Root Path="c:\incoming\" />
    </Storage>
  4. Save and close the cd_storage_conf.xml file.

Results

In this example, where items published to the file system were previously all saved to c:\incoming\, now, because you set defaultFilesystem to true, each item published to the file system is instead saved to c:\incoming\PubPUBID\, where PUBID is the identifier of the Publication that contains the item. For example, given that the Path attribute is set to c:\incoming\, then all items published to the file system from a Publication with ID 23 are stored in the folder c:\incoming\Pub23\.