exceptionfactory commented on code in PR #10351:
URL: https://github.com/apache/nifi/pull/10351#discussion_r2392916039


##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/test/java/org/apache/nifi/processors/elasticsearch/PutElasticsearchJsonTest.java:
##########
@@ -156,7 +156,7 @@ void testMigrateProperties() {
         
assertTrue(runner.getProcessContext().getProperties().keySet().stream().noneMatch(pd
 -> "put-es-json-not_found-is-error".equals(pd.getName())));
         
assertTrue(runner.getProcessContext().getProperties().keySet().stream().noneMatch(pd
 -> "put-es-json-error-documents".equals(pd.getName())));
 
-        assertEquals(1, result.getPropertiesRenamed().size());
+        assertTrue(1 < result.getPropertiesRenamed().size());

Review Comment:
   Is there a reason for this change? It seems like it should be reverted.



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/SearchElasticsearch.java:
##########
@@ -108,8 +109,7 @@ public class SearchElasticsearch extends 
AbstractPaginatedJsonQueryElasticsearch
             .build();
 
     static final PropertyDescriptor RESTART_ON_FINISH = new 
PropertyDescriptor.Builder()
-            .name("restart-on-finish")
-            .displayName("Restart On Finish?")
+            .name("Restart On Finish?")

Review Comment:
   In this case, the question mark should be removed:
   ```suggestion
               .name("Restart On Finish")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/PutElasticsearchRecord.java:
##########
@@ -203,17 +196,15 @@ public class PutElasticsearchRecord extends 
AbstractPutElasticsearch {
         .build();
 
     static final PropertyDescriptor AT_TIMESTAMP_RECORD_PATH = new 
PropertyDescriptor.Builder()
-        .name("put-es-record-at-timestamp-path")
-        .displayName("@timestamp Record Path")
+        .name("@timestamp Record Path")

Review Comment:
   Recommend changing this  property name, as the description still describes 
the `@timestamp` detail.
   ```suggestion
           .name("Timestamp Record Path")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-client-service-api/src/main/java/org/apache/nifi/elasticsearch/ElasticSearchClientService.java:
##########
@@ -172,17 +160,15 @@ Note that the Host is included in requests as a header 
(typically including doma
             "Fields that are missing (present in the schema but not in the 
record), or that have a value of null/empty, will be written out as a 
null/empty value");
 
     PropertyDescriptor SUPPRESS_NULLS = new PropertyDescriptor.Builder()
-            .name("el-cs-suppress-nulls")
-            .displayName("Suppress Null/Empty Values")
+            .name("Suppress Null/Empty Values")

Review Comment:
   ```suggestion
               .name("Suppress Null and Empty Values")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/PutElasticsearchRecord.java:
##########
@@ -143,17 +142,15 @@ public class PutElasticsearchRecord extends 
AbstractPutElasticsearch {
         .build();
 
     static final PropertyDescriptor AT_TIMESTAMP = new 
PropertyDescriptor.Builder()
-        .name("put-es-record-at-timestamp")
-        .displayName("@timestamp Value")
+        .name("@timestamp Value")

Review Comment:
   ```suggestion
           .name("Timestamp Value")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/PutElasticsearchRecord.java:
##########
@@ -247,8 +236,7 @@ public class PutElasticsearchRecord extends 
AbstractPutElasticsearch {
             .build();
 
     static final PropertyDescriptor RETAIN_AT_TIMESTAMP_FIELD = new 
PropertyDescriptor.Builder()
-        .name("put-es-record-retain-at-timestamp-field")
-        .displayName("Retain @timestamp (Record Path)")
+        .name("Retain @timestamp (Record Path)")

Review Comment:
   Recommend adjusting the name as follows:
   ```suggestion
           .name("Retain Record Timestamp")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/AbstractPutElasticsearch.java:
##########
@@ -107,8 +105,7 @@ public abstract class AbstractPutElasticsearch extends 
AbstractProcessor impleme
             .build();
 
     static final PropertyDescriptor NOT_FOUND_IS_SUCCESSFUL = new 
PropertyDescriptor.Builder()
-            .name("put-es-not_found-is-error")
-            .displayName("Treat \"Not Found\" as Success")
+            .name("Treat \"Not Found\" as Success")

Review Comment:
   Recommend removing the quotes:
   ```suggestion
               .name("Treat Not Found as Success")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-client-service-api/src/main/java/org/apache/nifi/elasticsearch/ElasticSearchClientService.java:
##########
@@ -139,26 +130,23 @@ Note that the Host is included in requests as a header 
(typically including doma
             .build();
 
     PropertyDescriptor CONNECT_TIMEOUT = new PropertyDescriptor.Builder()
-            .name("el-cs-connect-timeout")
-            .displayName("Connect timeout")
+            .name("Connect timeout")
             .description("Controls the amount of time, in milliseconds, before 
a timeout occurs when trying to connect.")
             .required(true)
             .defaultValue("5000")
             .addValidator(StandardValidators.POSITIVE_INTEGER_VALIDATOR)
             .build();
 
     PropertyDescriptor SOCKET_TIMEOUT = new PropertyDescriptor.Builder()
-            .name("el-cs-socket-timeout")
-            .displayName("Read timeout")
+            .name("Read timeout")
             .description("Controls the amount of time, in milliseconds, before 
a timeout occurs when waiting for a response.")
             .required(true)
             .defaultValue("60000")
             .addValidator(StandardValidators.POSITIVE_INTEGER_VALIDATOR)
             .build();
 
     PropertyDescriptor CHARSET = new PropertyDescriptor.Builder()
-            .name("el-cs-charset")
-            .displayName("Charset")
+            .name("Charset")

Review Comment:
   I recommend spelling out `Character Set`:
   ```suggestion
               .name("Character Set")
   ```



##########
nifi-extension-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-client-service-api/src/main/java/org/apache/nifi/elasticsearch/ElasticSearchClientService.java:
##########
@@ -139,26 +130,23 @@ Note that the Host is included in requests as a header 
(typically including doma
             .build();
 
     PropertyDescriptor CONNECT_TIMEOUT = new PropertyDescriptor.Builder()
-            .name("el-cs-connect-timeout")
-            .displayName("Connect timeout")
+            .name("Connect timeout")
             .description("Controls the amount of time, in milliseconds, before 
a timeout occurs when trying to connect.")
             .required(true)
             .defaultValue("5000")
             .addValidator(StandardValidators.POSITIVE_INTEGER_VALIDATOR)
             .build();
 
     PropertyDescriptor SOCKET_TIMEOUT = new PropertyDescriptor.Builder()
-            .name("el-cs-socket-timeout")
-            .displayName("Read timeout")
+            .name("Read timeout")

Review Comment:
   ```suggestion
               .name("Read Timeout")
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to