hudi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pratyaksh Sharma (Jira)" <j...@apache.org>
Subject [jira] [Commented] (HUDI-723) SqlTransformer's schema sometimes is not registered.
Date Fri, 20 Mar 2020 10:12:00 GMT

    [ https://issues.apache.org/jira/browse/HUDI-723?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17063261#comment-17063261
] 

Pratyaksh Sharma commented on HUDI-723:
---------------------------------------

Can you please share the stacktrace? 

> SqlTransformer's schema sometimes is not registered. 
> -----------------------------------------------------
>
>                 Key: HUDI-723
>                 URL: https://issues.apache.org/jira/browse/HUDI-723
>             Project: Apache Hudi (incubating)
>          Issue Type: Bug
>          Components: DeltaStreamer
>            Reporter: Alexander Filipchik
>            Priority: Major
>             Fix For: 0.6.0
>
>
> If schema is inferred from RowBasedSchemaProvider when SQL transformer is used it also
needs to be registered. 
>  
> Current way only works if SchemaProvider has a valid target schema. Is one wants to use
schema from SQL transformation, the result of RowBasedSchemaProvider.getTargetSchema needs
to be passed into something like:
> {code:java}
> private void setupWriteClient(SchemaProvider schemaProvider) {
>   LOG.info("Setting up Hoodie Write Client");
>   registerAvroSchemas(schemaProvider);
>   HoodieWriteConfig hoodieCfg = getHoodieClientConfig(schemaProvider);
>   writeClient = new HoodieWriteClient<>(jssc, hoodieCfg, true);
>   onInitializingHoodieWriteClient.apply(writeClient);
> }
> {code}
> Existent method will not work as it is checking for:
> {code:java}
> if ((null != schemaProvider) && (null == writeClient)) {
> {code}
> and writeClient is already configured. 
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message