Andy LoPresto created NIFI-3006:
-----------------------------------
Summary: Allow dynamic PropertyDescriptors to auto-populate
name/displayName
Key: NIFI-3006
URL: https://issues.apache.org/jira/browse/NIFI-3006
Project: Apache NiFi
Issue Type: Improvement
Components: Core Framework
Affects Versions: 1.0.0
Reporter: Andy LoPresto
Priority: Minor
As discussed during a review of [PR
1045|https://github.com/apache/nifi/pull/1045#discussion_r83525123], it would
be useful to allow dynamic {{PropertyDescriptor}} s to automatically populate
either the {{.name}} or {{.displayName}} field from the user-provided value.
This would likely involve writing utility methods for either {{humanize()}}
and/or {{symbolize()}}.
---
>From the PR comment:
Obviously the name is provided by the user at runtime, but should we still try
to define a {{displayName}} for the {{PropertyDescriptor}}? I could see three
possibilities:
* {{name}} and {{displayName}} are identical -- not much value
* {{name}} is as provided, {{displayName}} is the parameter passed through a
{{humanize()}}-type method (see below)
* {{displayName}} is as provided, {{name}} is the parameter passed through a
{{symbolize()}}-type method (see below)
The transform methods {{humanize()}}/{{symbolize()}} could be as simple as
title-casing and adding/removing spaces at word boundary guesses.
I'm not sure how much energy this is worth investing, as these property names
are not constants which will be retained across instances of the processor, but
I think they still would lose the state persisted in the {{flow.xml.gz}} if it
was somehow modified.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)