krisztina-zsihovszki commented on code in PR #6960:
URL: https://github.com/apache/nifi/pull/6960#discussion_r1113059607


##########
nifi-nar-bundles/nifi-salesforce-bundle/nifi-salesforce-processors/src/main/java/org/apache/nifi/processors/salesforce/QuerySalesforceObject.java:
##########
@@ -336,7 +347,7 @@ public void onTrigger(final ProcessContext context, final 
ProcessSession session
                                 getLogger(),
                                 writerFactory.getSchema(
                                         originalAttributes,
-                                        convertedSalesforceSchema.recordSchema
+                                        salesForceSchemaHolder.recordSchema

Review Comment:
   Minor: The recordSchema field is referenced directly while there is a getter 
method for salesforceObject field (getSalesforceObject()).



##########
nifi-nar-bundles/nifi-salesforce-bundle/nifi-salesforce-processors/src/test/java/org/apache/nifi/processors/salesforce/util/SalesforceToRecordSchemaConverterTest.java:
##########
@@ -130,10 +133,24 @@ void testSelectEmptyFields() throws IOException {
         final String salesforceSchemaFileName = "simple_sf_schema.json";
         final String fieldNames = "";
 
-        final RecordSchema expected = new 
SimpleRecordSchema(Collections.emptyList());
+        final RecordSchema expected = new SimpleRecordSchema(Arrays.asList(

Review Comment:
   Since the behavior is changed, I believe the testSelectAllFields() would be 
a better name for this test case.



##########
nifi-nar-bundles/nifi-salesforce-bundle/nifi-salesforce-processors/src/main/java/org/apache/nifi/processors/salesforce/QuerySalesforceObject.java:
##########
@@ -293,7 +297,14 @@ public void onTrigger(final ProcessContext context, final 
ProcessSession session
             ageFilterUpper = 
ageFilterUpperTime.format(DateTimeFormatter.ISO_OFFSET_DATE_TIME);
         }
 
-        ConvertedSalesforceSchema convertedSalesforceSchema = 
getConvertedSalesforceSchema(sObject, fields);
+        SalesForceSchemaHolder salesForceSchemaHolder = 
getConvertedSalesforceSchema(sObject, fields);

Review Comment:
   Minor: Please change the name to "SalesforceSchemaHolder" since the 
"Salesforce" format is used in all the other places, class and variable names.



-- 
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