hudi-agent commented on code in PR #18893:
URL: https://github.com/apache/hudi/pull/18893#discussion_r3417577198
##########
hudi-utilities/src/main/java/org/apache/hudi/utilities/schema/ProtoClassBasedSchemaProvider.java:
##########
@@ -79,21 +79,20 @@ public ProtoClassBasedSchemaProvider(TypedProperties props,
JavaSparkContext jss
}
@Override
- public Schema getSourceSchema() {
+ public HoodieSchema getSourceHoodieSchema() {
Review Comment:
🤖 Agreed, and there's a concrete caller that would break:
`hudi-integ-test/.../WriterContext.java:79` calls
`schemaProvider.getSourceSchema().toString()` on whatever provider is
configured via `cfg.schemaProviderClassName`. So swapping in any of
`ProtoClassBasedSchemaProvider`/`JdbcbasedSchemaProvider`/`RowBasedSchemaProvider`/`SchemaRegistryProvider`
post-merge would throw `UnsupportedOperationException` from the base class
default. A one-liner deprecated bridge (`return
getSourceHoodieSchema().toAvroSchema();`) on each, matching the pattern already
used in Filebased/Hive/Simple, keeps the legacy API working until callers are
migrated.
--
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]