ajantha-bhat commented on code in PR #8701:
URL: https://github.com/apache/iceberg/pull/8701#discussion_r1413885283


##########
core/src/main/java/org/apache/iceberg/avro/TypeToSchema.java:
##########
@@ -238,8 +247,51 @@ public Schema primitive(Type.PrimitiveType primitive) {
         throw new UnsupportedOperationException("Unsupported type ID: " + 
primitive.typeId());
     }
 
-    results.put(primitive, primitiveSchema);
+    cacheSchema(primitive, primitiveSchema);
 
     return primitiveSchema;
   }
+
+  static class WithTypeToName extends TypeToSchema {
+
+    private final Map<Type, Schema> results = Maps.newHashMap();
+
+    WithTypeToName(Map<Types.StructType, String> names) {
+      super((id, struct) -> names.get(struct));
+    }
+
+    Map<Type, Schema> getConversionMap() {

Review Comment:
   ```suggestion
       Map<Type, Schema> conversionMap() {
   ```



-- 
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: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to