Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
alamb commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2240801296 I plan to check this PR out carefully tomorrow -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
jayzhan211 commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2239052594 I think there is clear dependency something close to `Catalog` -> `Schema` -> `Table` -> `FileFormat` -> `QueryPlanner`. They all have trait and trait implementation and we c

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
jayzhan211 commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2239003792 I doubt that `CatalogSession` solves all the dependencies issue. `CatalogSession` is one higher level trait out of core. Others implementations are still leave inside core. If we

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
findepi commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2238975365 At runtime there are circular dependencies, unless we further limit amount of functionality available to the `TableProvider`. However, I think we actually solve the circular depen

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
jayzhan211 commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2238946024 Given the current `FileFormatFactory` implementation in datafusion, we only need `TableOptions`, we can change SessionState to `FileFormatContext ` with `TableOptions`, and it can

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-19 Thread via GitHub
findepi commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2238870621 > I think this is similar to minimum dependencies what I'm thinking. The only difference is that I propose `struct TableProviderContext`, but you have `trait CatalogSession` >

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-18 Thread via GitHub
jayzhan211 commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2236357455 > let CatalogSession contain things that are separate modules and not optional dependencies I think this is similar to minimum dependencies what I'm thinking. The only diff

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-18 Thread via GitHub
findepi commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2236188192 @jayzhan211 admittedly i made some choices about what to put into CatalogSession (or however we want to call this) and what to keep outside requiring a downcast to SessionState. m

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-17 Thread via GitHub
jayzhan211 commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2234919555 I think `CatalogSession` is not the minimum dependency, what is the reason to replace all the SessionState with CatalogSession -- This is an automated message from the Apache Gi

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-17 Thread via GitHub
findepi commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2234372485 Eventually all green. @jayzhan211 @alamb @comphead you may want to take a look -- This is an automated message from the Apache Git Service. To respond to the message, please

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-17 Thread via GitHub
findepi commented on code in PR #11516: URL: https://github.com/apache/datafusion/pull/11516#discussion_r1681386777 ## datafusion/catalog/src/table.rs: ## @@ -0,0 +1,293 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements.

Re: [PR] Extract catalog API to separate crate [datafusion]

2024-07-17 Thread via GitHub
findepi commented on PR #11516: URL: https://github.com/apache/datafusion/pull/11516#issuecomment-2233446186 This tries to implement the idea expressed in https://github.com/apache/datafusion/issues/10782#issuecomment-2233112949 -- This is an automated message from the Apache Git Service.

[PR] Extract catalog API to separate crate [datafusion]

2024-07-17 Thread via GitHub
findepi opened a new pull request, #11516: URL: https://github.com/apache/datafusion/pull/11516 This moves `CatalogProvider`, `TableProvider`, `SchemaProvider` to a new `datafusion-catalog` crate. The circular dependency between core `SessionState` and implementations is broken up by intro