GitHub user YolandaMDavis opened a pull request:

    https://github.com/apache/nifi/pull/564

    NIFI-2020 - Enhance JoltTransformJSON processor to support custom transforms

    This is the initial commit to enhance the JoltTransformJSON processor by 
providing the ability to support custom transformations via drop in 
jars/libraries.  
    
    The below describes the rules behind this enhancement:
    
    **Case #1 – Custom Transform Selected**
    
    In this case if the Custom option of Transform DSL is selected then 1) a 
Custom Transform Class Name should be entered and  2) one or more module paths 
should be provided.  The Custom Transform Class Name should be a **fully 
qualified classname** (e.g. eu.zacheusz.jolt.date.Dater). The Module Path can 
take a comma delimited list of directory locations or one or more jar files.  
Once these fields are populated the Advanced view will support validation and 
saving of the specification. **A user can switch between transformation types 
in the UI but not custom class names & module paths.**
    
    **Case #2 – Chain Transformation Selected with Custom Transformations 
embedded**
    
    In this case if a user wants to use one or more transforms (that include 
custom transformations) in their specification then the Chainr spec option can 
be used with one or more module path provides.  **In this case the Custom 
Transform Class Name property is not required and would be ignored (since one 
or more custom transformations could be invoked in the spec).**  As in Case #1 
the Advanced view will support validation and saving of specification if the 
required fields are populated for this case.
    
    To aid in testing, the Jolt Date custom transformation project can be used:
    
    [](https://github.com/zacheusz/jolt-date)
    
    A jar file can be built from this project and used for testing
    
    Also a readme file with example specification for jolt-date is attached 
along with snapshots of configuration setup and execution.
    [README.txt](https://github.com/apache/nifi/files/329176/README.txt)
    
![nifi-2020_custom_configuration](https://cloud.githubusercontent.com/assets/1371858/16291351/ffae7736-38d3-11e6-9b40-48cecaf64d77.jpg)
    
![nifi-2020_advancedui_custom](https://cloud.githubusercontent.com/assets/1371858/16291354/029bbb2a-38d4-11e6-88dc-7bd9689f3a83.jpg)

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/YolandaMDavis/nifi NIFI-2020-master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/nifi/pull/564.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #564
    
----
commit 6daa9df25490f5f07b23293e752e947394af42e7
Author: Yolanda M. Davis <[email protected]>
Date:   2016-06-23T02:26:16Z

    NIFI-2020 - initial commit for custom transformation support

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to