You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flink.apache.org by "Dian Fu (JIRA)" <ji...@apache.org> on 2019/06/26 06:00:00 UTC

[jira] [Created] (FLINK-12991) Correct the implementation of Catalog.get_table_factory

Dian Fu created FLINK-12991:
-------------------------------

             Summary: Correct the implementation of Catalog.get_table_factory
                 Key: FLINK-12991
                 URL: https://issues.apache.org/jira/browse/FLINK-12991
             Project: Flink
          Issue Type: Bug
          Components: API / Python
            Reporter: Dian Fu


The following method is added in catalog.py in FLINK-11480:
{code:java}
def get_table_factory(self): 
    """ 
    Get an optional TableFactory instance that's responsible for     
    generating source/sink for tables stored in this catalog. :return: An 
    optional TableFactory instance.
    """ 
    return self._j_catalog.getTableFactory()

{code}
There is some problem with the implementation as it returns a Java TableFactory and this is not friendly for Python users. We should correct the implementation. 

Before doing that, we need to make sure the following thing:
Is this method designed to be used by users or it will only be used internally? I take a quick look at the code and it seems to me that this method will only be used internally. Maybe [~xuefuz] and [~phoenixjiangnan] can provide more information about this?

If this method will be used by users directly, we need to provide a Python TableFactory wrapper and makes sure the this method is usable for Python users. If this method is designed to be only used internally, then we need to remove it from the Python catalog. For the API completeness test, we can add this method to excluded_methods of CatalogAPICompletenessTests to make the tests passed.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)