I am using DD4T on an SDL Tridion project and am using the following configuration in the storage config in order to publish Binaries (binaries in this case being anything store in Multimedia Components) to the filesystem but keep Pages in the Content Delivery database.
I am finding that as requirements change for what Binary files are needed e.g. the customer wants to offer Adobe Illustrator files for download, I am needing to add more types to the list by changing the config and restarting the deployer which is not ideal.
<ItemTypes defaultStorageId="defaultdb" cached="false">
<Item typeMapping="Page" cached="false" storageId="defaultFile"/>
<Publication Id="9" defaultStorageId="defaultdb" cached="true">
<Item typeMapping="Binary" itemExtension=".jpg" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".gif" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".pdf" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".doc" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".docx" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".xls" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".xlsx" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".xlsm" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".jpeg" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".png" storageId="defaultFile" cached="true"/>
<Item typeMapping="Binary" itemExtension=".ico" storageId="defaultFile" cached="true"/>
</Publication>
</ItemTypes>
Can anyone tell me if there is a way to change the above so that the contents of all Multimedia Components for the given publication go to the filesystem? I can't seem to find this in the documentation.
As far as I know, the less you specify, the less you filter. Have you tried omitting the
itemExtension
attribute altogether? I would expect this then to apply to any extension.We use the following in our configuration and it picks up any new binary file types we add without require a change to the storage configuration:
You would just need to update to use your storage end point and desired cache setting:
Just strip out the itemExtension node, and it will deploy all binaries to that storage id. The extensions are really only for exceptions.