TransformXml

Description:

Applies the provided XSLT file to the FlowFile XML payload. A new FlowFile is created with transformed content and is routed to the 'success' relationship. If the XSL transform fails, the original FlowFile is routed to the 'failure' relationship

Tags:

xml, xslt, transform

Properties:

In the list below, the names of required properties appear in bold. Any other properties (not in bold) are considered optional. The table also indicates any default values, and whether a property supports the NiFi Expression Language.

NameDefault ValueAllowable ValuesDescription
XSLT file nameProvides the name (including full path) of the XSLT file to apply to the FlowFile XML content.One of the 'XSLT file name' and 'XSLT Lookup' properties must be defined.

This property requires exactly one file to be provided..

Supports Expression Language: true (will be evaluated using flow file attributes and variable registry)
XSLT LookupController Service API:
StringLookupService
Implementations: SimpleScriptedLookupService
CouchbaseKeyValueLookupService
SimpleCsvFileLookupService
ElasticSearchStringLookupService
PropertiesFileLookupService
XMLFileLookupService
SimpleKeyValueLookupService
SimpleDatabaseLookupService
DistributedMapCacheLookupService
Controller lookup used to store XSLT definitions. One of the 'XSLT file name' and 'XSLT Lookup' properties must be defined. WARNING: note that the lookup controller service should not be used to store large XSLT files.
XSLT Lookup keyKey used to retrieve the XSLT definition from the XSLT lookup controller. This property must be set when using the XSLT controller property.
Supports Expression Language: true (will be evaluated using flow file attributes and variable registry)
Indenttrue
  • true
  • false
Whether or not to indent the output.
Secure processingtrue
  • true
  • false
Whether or not to mitigate various XML-related attacks like XXE (XML External Entity) attacks.
Cache size10Maximum number of stylesheets to cache. Zero disables the cache.
Cache TTL after last access60 secsThe cache TTL (time-to-live) or how long to keep stylesheets in the cache after last access.

Dynamic Properties:

Dynamic Properties allow the user to specify both the name and value of a property.

NameValueDescription
An XSLT transform parameter nameAn XSLT transform parameter valueThese XSLT parameters are passed to the transformer
Supports Expression Language: true (will be evaluated using flow file attributes and variable registry)

Relationships:

NameDescription
successThe FlowFile with transformed content will be routed to this relationship
failureIf a FlowFile fails processing for any reason (for example, the FlowFile is not valid XML), it will be routed to this relationship

Reads Attributes:

None specified.

Writes Attributes:

None specified.

State management:

This component does not store state.

Restricted:

This component is not restricted.

Input requirement:

This component requires an incoming relationship.

System Resource Considerations:

None specified.