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

Caizhi Weng commented on FLINK-20187:
-------------------------------------

[~liufangliang] please take a look.

> FactoryUtil#createTableSource will be confused by a table source and a table 
> sink factory with same identifier
> --------------------------------------------------------------------------------------------------------------
>
>                 Key: FLINK-20187
>                 URL: https://issues.apache.org/jira/browse/FLINK-20187
>             Project: Flink
>          Issue Type: Bug
>          Components: Table SQL / API
>    Affects Versions: 1.12.0
>            Reporter: Caizhi Weng
>            Priority: Major
>             Fix For: 1.12.0
>
>
> When creating a table source I'm faced with the following exception:
> ```
> Caused by: org.apache.flink.table.api.ValidationException: Multiple factories 
> for identifier 'odps' that implement 
> 'org.apache.flink.table.factories.DynamicTableFactory' found in the classpath.
> Ambiguous factory classes are:
> ```
> However there is only one table source factory with this identifier, and 
> another table sink factory with this identifier. 
> {{FactoryUtil#createTableSource}} shouldn't be confused.
> This is caused by {{FactoryUtil.java}} line 370, where {{factory = 
> discoverFactory(context.getClassLoader(), DynamicTableFactory.class, 
> connectorOption);}} should be {{factory = 
> discoverFactory(context.getClassLoader(), factoryClass, connectorOption);}}.



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

Reply via email to