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

jackylau commented on FLINK-16698:
----------------------------------

hi [~jark] [~bli], i prepare to define a interface such as CatalogListener such 
as

public interface CatalogListener {

 void preCreateTable(ObjectPath tablePath, CatalogBaseTable table, boolean 
ignoreIfExists);

 void afterCreateTable(ObjectPath tablePath, CatalogBaseTable table, boolean 
ignoreIfExists);

}

then triger in TableEnvironmentImpl(becase CatalogManager don't have 
createDatabase method)

listener.forEach(lister.preCreataTable)

catalog.createTable

listener.forEach(lister.afterCreataTable)

 

and we parser conf by reflection to register CatalogListener.

Is it a good design? And I see the code of spark and hive ,both of them 
implement it by define Event.

 

> fllink need catalog listener to do such as preCreate/PreDrop* 
> afterCreate/AfterDrop* things
> -------------------------------------------------------------------------------------------
>
>                 Key: FLINK-16698
>                 URL: https://issues.apache.org/jira/browse/FLINK-16698
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table SQL / Planner
>    Affects Versions: 1.10.0
>            Reporter: jackylau
>            Priority: Major
>             Fix For: 1.11.0
>
>
> In order to support other things such as atlas or authentication, i think 
> flink need catalog listener to do such as preCreate/PreDrop* 
> afterCreate/AfterDrop* things, just like spark/hive does



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

Reply via email to