haizhou-zhao commented on code in PR #19645:
URL: https://github.com/apache/flink/pull/19645#discussion_r868618419
##########
flink-formats/flink-avro/src/main/java/org/apache/flink/formats/avro/typeutils/GenericRecordAvroTypeInfo.java:
##########
@@ -104,10 +105,15 @@ public boolean canEqual(Object obj) {
}
private void writeObject(ObjectOutputStream oos) throws IOException {
- oos.writeUTF(schema.toString());
+ byte[] schemaStrInBytes =
schema.toString(false).getBytes(StandardCharsets.UTF_8);
Review Comment:
@tweise @stevenzwu I think the avro serializer snapshot (which is used for
de/ser operator state if the state include Avro record) already takes care of
de/ser of large Avro schema: Code
[link](https://github.com/apache/flink/blob/master/flink-formats/flink-avro/src/test/java/org/apache/flink/formats/avro/typeutils/AvroSerializerSnapshotTest.java#L155).
Since the serialization of avro serializer and typeinfo is only used when
constructing edge and vertices of stream graph, maybe we don't need to take
care of backward compatibility here.
--
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]