Skip to content

Test Transform

Axel Faust edited this page Jul 22, 2017 · 1 revision

The Test Transform tool allows to check and modify transformation configurations, as well as to review and test the availability of configured transformers. This allows to dynamically change e.g. supported transformations or transformation limits as would typically be done via the alfresco-global.properties / transformer.properties (documented as part of content transformer dev extension point) without requiring a restart of the system. This can be used for development purposes as well as to temporarily disable certain transformations that may cause problems in a production system.

Test Transform tool

Transformer Properties

This section provides a view of all effective or custom transformer configuration properties for the "Transformers" subsystem. The view displays those settings as properties so that any setting could potentially be transferred directly into alfresco-global.properties to affect permanent changes. All configurations with default values will be displayed as commented-out properties ("#" prefix). Note: Even if the "Transformers" susbystem is extended by a custom alfresco/subsystems/Transformers/default/*.properties file, only the properties from the transformers.properties file in that subsystem default directory will be considered for differentiation between default and custom values. This is a limitation of the core class TransformerProperties which hardcodes the default configuration file instead of respecting subsystem configuration concepts.

Set Transformer Properties

This section allows to set configuration properties to different values, thereby overriding default values or previously customised ones. The textarea takes configuration properties in the same format as used in properties files, and multiple properties can be set in one atomic operation.

Remove Transformer Properties

This section allows to remove custom (new) configuration properties that have been dynamically set via the "Set Transformers Properties". The textarea takes configuration properties as property keys separated by newline, so one property name per line. Configuration properties that were defined in the default transformers.properties file and have only been modified cannot be removed - they must be reset to the default value via the "Set Transformer Properties" section.

Transformation Log

Retrieves the last entries in the transformation log. This requires that transformers and other services explicitly log via the API class TransformerLogger using the Spring bean "transformerLog". The logger can contain up to 1000 entries, and administrators may set a different limit (between 1 and 1000) via the transformer property "transformer.log.entries".

Transformation Debug Log

Retrieves the last entries in the transformation debug log. This requires that transformers and other services explicitly log via the API class TransformerLogger using the Spring bean "transformerDebugLog". The logger can contain up to 100 entries but starts without a specific limit set (disabled). Administrators may set a limit (between 1 and 100) via the transformer property "transformer.debug.entries", and thus enable the debug log.

Transformer Names

Lists all currently registered transformers in the Alfresco Repository.

Transformation Statistics

Shows the transformation statistics for one or multiple transformers. The view can be restricted by selecting a specific transformer or defining a particular (set of) transformation by specifying the source/target mimetype.

Test Transform

Triggers an execution of a test transformation, which will use a small test file and try to transform it according to the selected options. The dynamic selection of potential transformers can be influenced by selecting a specific transformer, context or combination of source/target mimetypes.

Historically undocumented, Alfresco has shipped small sample files for multiple mimetypes at least since Alfresco 4.2. These are resolved via the classpath:quick/quick.<extension> pattern. This allows administrators to provide test files for any mimetype by putting a quick.XXX file in shared/classes/quick/, though it is not possible to override the default files unless the custom files are packaged in the WEB-INF/classes/quick/ path within the Repository web application. The extension to be used is determined by mimetypes registered with the Alfresco MimetypeService, e.g. via mimetype maps.

Transformations By Extension

Lists possible transformation paths for particular source/target mimetypes and context without actually performing a transformation and considering any size limits. The resulting list reflects the priority with which transformations would be attempted.

Transformations By Transformer

Lists possible transformations for a particular transformer and context.