You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2019/07/12 09:58:56 UTC

[GitHub] [nifi] Riduidel commented on a change in pull request #3570: Fix for NIFI-6422

Riduidel commented on a change in pull request #3570: Fix for NIFI-6422
URL: https://github.com/apache/nifi/pull/3570#discussion_r302914673
 
 

 ##########
 File path: nifi-nar-bundles/nifi-gcp-bundle/nifi-gcp-processors/src/main/java/org/apache/nifi/processors/gcp/bigquery/BigQueryUtils.java
 ##########
 @@ -37,29 +38,51 @@
     private final static Type gsonSchemaType = new TypeToken<List<Map>>() { }.getType();
 
     public static Field mapToField(Map fMap) {
-        String typeStr = fMap.get("type").toString();
+        String typeStr = fMap.get("type").toString().toUpperCase();
         String nameStr = fMap.get("name").toString();
-        String modeStr = fMap.get("mode").toString();
+        String modeStr;
+        if(fMap.containsKey("mode")) {
+        	modeStr = fMap.get("mode").toString();
+        } else {
+        	modeStr = Mode.NULLABLE.name();
+        }
         LegacySQLTypeName type = null;
 
 Review comment:
   I don't understand. Whcih default case are you talking about ?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services