gszadovszky commented on code in PR #3272:
URL: https://github.com/apache/parquet-java/pull/3272#discussion_r2306695111


##########
parquet-avro/src/main/java/org/apache/parquet/avro/AvroSchemaConverter.java:
##########
@@ -150,16 +151,23 @@ public MessageType convert(Schema avroSchema) {
     if (!avroSchema.getType().equals(Schema.Type.RECORD)) {
       throw new IllegalArgumentException("Avro schema must be a record.");
     }
-    return new MessageType(avroSchema.getFullName(), 
convertFields(avroSchema.getFields(), ""));
+    return new MessageType(
+        avroSchema.getFullName(),
+        convertFields(avroSchema.getFields(), "", new IdentityHashMap<Schema, 
Integer>()));

Review Comment:
   You don't need a map, only a set since you only add the same element once. 
(Maybe use `HashSet`?)
   
   Isn't it enough to use the type name only instead of the whole `Schema` 
object?



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to