Github user kevdoran commented on a diff in the pull request:

    https://github.com/apache/nifi-registry/pull/133#discussion_r208953844
  
    --- Diff: nifi-registry-docs/src/main/asciidoc/administration-guide.adoc ---
    @@ -1094,3 +1094,63 @@ Here is the data model version histories:
     |2|0.2|JSON formatted text file. The root object contains header and Flow 
content object.
     |1|0.1|Binary format having header bytes at the beginning followed by Flow 
content represented as XML.
     |====
    +
    +== Event Hooks
    +Event hooks are an integration point that allows for custom code to to be 
triggered when NiFi Registry application events occur.
    +
    +[options="header,footer"]
    
+|==================================================================================================================================================
    +| Event Name | Description
    +|`CREATE_BUCKET` | A new registry bucket is created.
    +|`CREATE_FLOW` | A new flow is created in a specified bucket. Only 
triggered on first time creation of a flow with a given name.
    +|`CREATE_FLOW_VERSION` | A new version for a flow has been saved in the 
registry.
    +|`UPDATE_BUCKET` | A bucket has been updated.
    +|`UPDATE_FLOW` | A flow that exist in a bucket has been updated.
    +|`DELETE_BUCKET` | An existing bucket in the registry is deleted.
    +|`DELETE_FLOW` | An existing flow in the registry is deleted.
    
+|==================================================================================================================================================
    +
    +=== Shared Event Hook Properties
    +There are certain properties that are shared amongst all of the NiFi 
Registry provided Event Hook implementations. Those properties and
    +their purpose are listed below.
    +
    +[options="header,footer"]
    
+|==================================================================================================================================================
    +| Property Name | Description
    +|`Event Whitelist` | A comma separated list of events the the hook 
provider configured with this property should respond to. If this property is 
left blank or not provided all events will fire for the configured hook 
provider.
    
+|==================================================================================================================================================
    +
    +=== ScriptEventHookProvider
    +Hook provider for invoking a shell script that has been written by a user 
and placed on a file system that is accessible
    +by the NiFi Registry instance that the provider is configured for.
    +
    +....
    +<eventHookProvider>
    +    <class>
    +      org.apache.nifi.registry.provider.hook.ScriptEventHookProvider
    +    </class>
    +    <property name="Script Path"></property>
    +    <property name="Working Directory"></property>
    +    <!-- optional -->
    +    <property name="Event Whitelist">CREATE_FLOW,UPDATE_FLOW</property>
    --- End diff --
    
    Comma-separated lists in XML is inconsistent with how we handle configuring 
lists in other contexts. For example, the initial user identities in 
Authorizers.xml:
    
    ```
        <!--
            The FileUserGroupProvider will provide support for managing users 
and groups which is backed by a file
            on the local file system.
    
            - Users File - The file where the FileUserGroupProvider will store 
users and groups.
    
            - Initial User Identity [unique key] - The identity of a users and 
systems to seed the Users File. The name of
                each property must be unique, for example: "Initial User 
Identity A", "Initial User Identity B",
                "Initial User Identity C" or "Initial User Identity 1", 
"Initial User Identity 2", "Initial User Identity 3"
    
                NOTE: Any identity mapping rules specified in 
nifi-registry.properties will also be applied to the user identities,
                so the values should be the unmapped identities (i.e. full DN 
from a certificate).
        -->
        <userGroupProvider>
            <identifier>file-user-group-provider</identifier>
            
<class>org.apache.nifi.registry.security.authorization.file.FileUserGroupProvider</class>
            <property name="Users File">./conf/users.xml</property>
            <property name="Initial User Identity 1"></property>
        </userGroupProvider>
    ```
    
    We may want to reconsider in order to keep this consistent....


---

Reply via email to