OpenWGA 7.9 - OpenWGA Concepts and Features

Design and development » File derivates

How derivates are created

After patching your content stores to version 5 patch level 4 and upgrading the file storage format these content store are able to store file derivates. Derivate creation however happens automatically. A derivate update process runs regularly and looks through all file attachments on all content documents if there are file derivate creators able to create derivates for them. If so these derivates are created (or updated). The derivates are stored separately from their original file attachments and their documents, however they are also automatically deleted when the original is removed.

A file derivate creator is an OpenWGA java module which is able to create derivates for certain types of files. Vanilla OpenWGA installations come with a "Thumbnail Derivate Creator" preinstalled and configured which will create scaled down versions of PNG, JPG and BMP files. Per default in the following sizes:

  • 2048 pixel width with the matching height regarding aspect ratio
  • 1024 pixel width ...
  • 768 pixel width ...
  • 320 pixel width ...
  • 100 pixel width ...

You can modify these sizes per app by setting publisher option "File Derivates: Thumbnails: Sizes" to your desired values. After that you need to manually start the update of all derivates for the change to come into effect. This can be done in OpenWGA admin clients "Expert mode" (checkbox to the top right). On the web app configuration display there now should be an item "Update file derivates" on the "Database" menu .

Other file derivate creators can be developed as OpenWGA java modules for various other purposes.

You can see the file derivates that are created for individual files in the DB-Explorer in admin client (Menu "Tools" > "DB-Explorer"). Navigate there to a page  which you know to have PNG/JPG/BMP images as attachments on the content document. Open the content document from the list and switch to tab "Attachments". There you will find a link on the right of each image attachment, denoting the number of derivates that are available for this file. Clicking it will reveal details of those derivates:

screenshot at 2014-03-26 09:21:25.png

You can also see what the file derivate update process is currently doing. Again in OpenWGA admin client, Menu "Runtime" > "Status", you will find this line, showing you the currently executed task of this process:

screenshot at 2014-03-26 09:20:19.png

Updating derivates

File derivates are automatically created or removed when new derivate creators are installed or removed. However if you change the configuration of a derivate creator - for example change the sizes of created thumbnails via publisher option "File Derivates: Thumbnails: Sizes" - then you have to manually trigger the update of the affected derivates.

You can do so from a web app configuration in OpenWGA admin client when in "expert mode" (checkbox to the top right). On the "Database" actions menu of the configuration (on the right of section "Contentstore configuration") you will find an action "Update file derivates":

screenshot_09.png

Clicking it will bring up a choice of derivate creators, whose derivates need to be updated:

screenshot at 2014-04-02 15:49:05.png

Select the derivate creators whose configuration was updated and click the button to start the process. If you are running a cluster this will only be possible on the cluster node where the derivate update process actually runs (normally the master node unless otherwise configured).