[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-12 Thread Yubin Li (Jira)


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

Yubin Li commented on FLINK-33780:
--

[~hackergin] [~Leonard]  Thanks for your review :D

It maybe more appropriate to initialize the default catalog when calling 
`Builder.defaultCatalog` rather than when building `CatalogManager`, but 
introducing a new method in `CatalogManger.Builder` requires changing all 
related calls.

If we adopt the solution, there is only one minor comment that 
`CatalogDescriptor` has already included `catalogName`, so it may be more 
appropriate to use `defaultCatalog(CatalogDescriptor catalogDescriptor)`. WDYT?

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png, 
> image-2023-12-11-14-14-10-002.png, image-2023-12-12-11-09-53-075.png, 
> image-2023-12-12-13-42-04-762.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-12 Thread Feng Jin (Jira)


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

Feng Jin commented on FLINK-33780:
--

cc [~Leonard]

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png, 
> image-2023-12-11-14-14-10-002.png, image-2023-12-12-11-09-53-075.png, 
> image-2023-12-12-13-42-04-762.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-12 Thread Feng Jin (Jira)


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

Feng Jin commented on FLINK-33780:
--

[~liyubin117]  I agree that saving default_catalog to CatalogStore is a good 
idea. However, I think that creating an in-memory catalog as the default 
catalog  may not be the most suitable approach.

I suggest introducing a new method in 
org.apache.flink.table.catalog.CatalogManager.Builder called 
defaultCatalog(String defaultCatalogName, CatalogDescriptor catalogDescriptor). 
This method would allow specifying a CatalogDescriptor for the default catalog, 
similar to how CatalogManager.createCatalog works.


WDYT ? 

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png, 
> image-2023-12-11-14-14-10-002.png, image-2023-12-12-11-09-53-075.png, 
> image-2023-12-12-13-42-04-762.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-11 Thread Yubin Li (Jira)


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

Yubin Li commented on FLINK-33780:
--

[~hackergin] Hi, we could make modifitions in the `CatalogManager` construct 
function as follows:

!image-2023-12-12-11-09-53-075.png|width=1165,height=593!

DefaultCatalog is the current catalog of a session including SqlGateway, 
`default_catalog` is like `d2`, only the difference is that it is created 
implicitly by Flink, we should treat them equally for semantic consistency, 
WDYT?

!image-2023-12-11-14-14-10-002.png|width=805,height=565!

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png, 
> image-2023-12-11-14-14-10-002.png, image-2023-12-12-11-09-53-075.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-11 Thread Feng Jin (Jira)


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

Feng Jin commented on FLINK-33780:
--

[~liyubin117]  `default_catalog` is usually registered by the Catalog instance. 
I'm wondering what we need to do if we want to save default_catalog to 
CatalogStore. Especially in SqlGateway, DefaultCatalog is not necessarily 
GenericInMemory.  I think  these temporary catalogs should not support `show 
create catalog` ?

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png, 
> image-2023-12-11-14-14-10-002.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-10 Thread Yubin Li (Jira)


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

Yubin Li commented on FLINK-33780:
--

[~hackergin] In addition to the conceptual necessity (default catalog is also 
part of catalogs), I also found that the `show create catalog` statement  
proposed in https://issues.apache.org/jira/browse/FLINK-24939 would expose the 
absence of the default catalog in the CatalogStore.

!image-2023-12-11-13-47-29-623.png|width=702,height=290!

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
> Attachments: image-2023-12-11-13-47-29-623.png
>
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-10 Thread Feng Jin (Jira)


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

Feng Jin commented on FLINK-33780:
--

Hi, [~liyubin117]  Thanks for pointing this .  could you provide a more 
detailed description of what problems may arise if we don't save the default 
catalog ?

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Commented] (FLINK-33780) Support to store default catalog in CatalogStore

2023-12-08 Thread Yubin Li (Jira)


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

Yubin Li commented on FLINK-33780:
--

[~hackergin] Hi, looking forward to your suggestions :) I have implemented 
this, and if it is neccessary, could you please assign this to me? thanks~

> Support to store default catalog in CatalogStore
> 
>
> Key: FLINK-33780
> URL: https://issues.apache.org/jira/browse/FLINK-33780
> Project: Flink
>  Issue Type: Sub-task
>  Components: Table SQL / API
>Affects Versions: 1.19.0
>Reporter: Yubin Li
>Priority: Major
>
> Flink initially creates a default catalog which is included in the 
> `Map catalogs`, but is not stored in the CatalogStore.
> After conducting thorough investigation, I've determined that the necessary 
> modification can be made within the `CatalogManager`.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)