Github user otherview commented on a diff in the pull request:
https://github.com/apache/nifi/pull/2287#discussion_r152830029
--- Diff:
nifi-nar-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-5-processors/src/main/java/org/apache/nifi/processors/elasticsearch/PutElasticsearch5.java
---
@@ -196,6 +205,7 @@ public void onTrigger(final ProcessContext context,
final ProcessSession session
final String index =
context.getProperty(INDEX).evaluateAttributeExpressions(file).getValue();
final String docType =
context.getProperty(TYPE).evaluateAttributeExpressions(file).getValue();
final String indexOp =
context.getProperty(INDEX_OP).evaluateAttributeExpressions(file).getValue();
+ final Long version = version_attribute != null ?
Long.parseLong(file.getAttribute(version_attribute)) : null;
--- End diff --
From my understanding this field is suppose to take the flowfile attribute
name, thats why I went with ATTRIBUTE_KEY_VALIDATOR .
I'm updating the code to use .asLong() instead ! :)
---