Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

evgenii/fix limit rewrite #100

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
a25a523
Update to DataFusion 37.1
phillipleblanc May 9, 2024
a852cd3
Allow TableScans of non-federated sources
phillipleblanc May 9, 2024
c81a766
.clone() -> Arc::clone(&
phillipleblanc May 9, 2024
c6c9542
Update Cargo.toml license to Apache-2.0
phillipleblanc May 9, 2024
4808d74
Merge branch 'main' into spiceai
phillipleblanc May 10, 2024
5d9b98f
Upgrade to DataFusion 38
phillipleblanc May 13, 2024
3de50a9
Add fallback TableProvider to FederatedTableProviderAdaptor
phillipleblanc May 14, 2024
0fadae1
Make connectorx optional
phillipleblanc May 14, 2024
8ba03bd
Rewrite all table scans to use federated table name (#4)
phillipleblanc May 16, 2024
8fcda49
Rewrite subquery table scans to point to remote table (#5)
phillipleblanc May 20, 2024
1c77d8c
Fix the fallback to the table provider for supports_filters_pushdown
phillipleblanc May 24, 2024
b221f4e
Use SpiceAI datafusion fork
phillipleblanc May 24, 2024
f5d4797
Fix the table scan rewrite to properly rewrite column relations (#3)
phillipleblanc May 27, 2024
532ecd0
Handle table rewrites for aggregation functions
phillipleblanc May 27, 2024
f5d20bb
Update datafusion version
phillipleblanc May 29, 2024
65d4be2
Use Unparser Dialect for plan_to_sql
phillipleblanc May 22, 2024
6d714cb
Use unparser Dialect
phillipleblanc May 29, 2024
9dc7404
bump datafusion fork
phillipleblanc May 29, 2024
bf5fac6
Add layer to convert actual schema to expected schema
phillipleblanc May 30, 2024
4ea973e
Update datafusion-federation to datafusion 39 (#6)
phillipleblanc Jun 11, 2024
e85aa96
Improve rewrite logic for expressions
sgrebnov Jun 12, 2024
15d4bd9
update spiceai datafusion to include new unparsers logic (#8)
y-f-u Jun 24, 2024
776930f
Update datafusion to include time predicate fix (#9)
sgrebnov Jun 26, 2024
c3f696a
Remove table reference mutating during logical planning, converting q…
y-f-u Jun 27, 2024
1becf0c
Update SpiceAI Datafusion fork
phillipleblanc Jul 8, 2024
77548d3
Upgrade to DF 40
phillipleblanc Jul 15, 2024
f430401
Bump datafusion-federation version to 0.1.5
phillipleblanc Jul 15, 2024
eeb9b9c
do not over eager rewrite column when col relation is there (#12)
y-f-u Jul 15, 2024
9b4392f
Upgrade to DataFusion v41
phillipleblanc Aug 14, 2024
ae9da45
Use `Display` for displaying federated plans
phillipleblanc Aug 15, 2024
21cfcc8
Make the `FederatedPlanner` public for use in custom query planners (…
phillipleblanc Aug 22, 2024
2cb3330
Add List types parsing support to schema cast (#13)
sgrebnov Aug 25, 2024
e0a4eae
Add interval cast given original schema (#15)
Sevenannn Aug 25, 2024
21f07be
Add Structs parsing support to schema cast (#16)
sgrebnov Aug 26, 2024
b668294
feat: Add AST analyzer middleware (#19)
peasee Aug 30, 2024
7c69f7b
Upgrade to DF 42 & Arrow 53
phillipleblanc Sep 18, 2024
f1e7b17
Preserve records batch order when SchemaCastScanExec is involved (#20)
sgrebnov Oct 9, 2024
06b9000
Support for rewriting plans with UNNEST (#21)
sgrebnov Oct 17, 2024
ce1ce61
Correctly handle unnest by FederationAnalyzerRule (#22)
sgrebnov Oct 18, 2024
0aabd42
Filters push down optimization for federation queries (#23)
sgrebnov Oct 21, 2024
914bd08
Run `optimize_projections` as part of federated plan optimization (#24)
sgrebnov Nov 4, 2024
5af0df8
Upgrade to DF 43
phillipleblanc Nov 12, 2024
bbc0f89
Add own modified version of Datafusion `optimize_projections` rule (#25)
sgrebnov Nov 29, 2024
04487ba
Federation analyzer should federate the subquery when possible (#26)
Sevenannn Dec 23, 2024
72374f6
Fix unnest rewriting logic (#28)
sgrebnov Dec 24, 2024
884b2a5
fix: clean up outdated dependencies & modules and fix tests (#32)
Sevenannn Dec 26, 2024
ce91d5a
fix: rewrite shouldn't be performed on a column name same as the tabl…
Sevenannn Dec 27, 2024
4c0ff79
fix: don't rewrite table names inside subquery when engine doesn't su…
Sevenannn Dec 30, 2024
5832471
Handle LogicalPlan::Limit separately to preserve skip and offset in r…
ewgenius Jan 2, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
- run: npm install prettier prettier-plugin-toml
- run: npx prettier --check --no-config .
- run: npx prettier --write --no-config .
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
/node_modules
package-lock.json
package.json
.DS_Store
213 changes: 213 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,213 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in library 'datafusion_federation'",
"cargo": {
"args": [
"test",
"--no-run",
"--lib",
"--package=datafusion-federation"
],
"filter": {
"name": "datafusion_federation",
"kind": "lib"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug example 'sqlite'",
"cargo": {
"args": [
"build",
"--example=sqlite",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "sqlite",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in example 'sqlite'",
"cargo": {
"args": [
"test",
"--no-run",
"--example=sqlite",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "sqlite",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug example 'flight-sql'",
"cargo": {
"args": [
"build",
"--example=flight-sql",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "flight-sql",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in example 'flight-sql'",
"cargo": {
"args": [
"test",
"--no-run",
"--example=flight-sql",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "flight-sql",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug example 'postgres-partial'",
"cargo": {
"args": [
"build",
"--example=postgres-partial",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "postgres-partial",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in example 'postgres-partial'",
"cargo": {
"args": [
"test",
"--no-run",
"--example=postgres-partial",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "postgres-partial",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug example 'sqlite-partial'",
"cargo": {
"args": [
"build",
"--example=sqlite-partial",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "sqlite-partial",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in example 'sqlite-partial'",
"cargo": {
"args": [
"test",
"--no-run",
"--example=sqlite-partial",
"--package=datafusion-federation-examples"
],
"filter": {
"name": "sqlite-partial",
"kind": "example"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in library 'datafusion_federation_flight_sql'",
"cargo": {
"args": [
"test",
"--no-run",
"--lib",
"--package=datafusion-federation-flight-sql"
],
"filter": {
"name": "datafusion_federation_flight_sql",
"kind": "lib"
}
},
"args": [],
"cwd": "${workspaceFolder}"
},
{
"type": "lldb",
"request": "launch",
"name": "Debug unit tests in library 'datafusion_federation_sql'",
"cargo": {
"args": [
"test",
"--no-run",
"--lib",
"--package=datafusion-federation-sql"
],
"filter": {
"name": "datafusion_federation_sql",
"kind": "lib"
}
},
"args": [],
"cwd": "${workspaceFolder}"
}
]
}
13 changes: 9 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,20 @@ members = [
[patch.crates-io]
# connectorx = { path = "../connector-x/connectorx" }
# datafusion = { path = "../arrow-datafusion/datafusion/core" }
# Pending next Datafusion release with `unnest` unparsing support
datafusion = { git = "https://github.com/spiceai/datafusion.git", rev = "0bad328656a07fd5ab899186462b09e119e21f90" }

[workspace.package]
version = "0.1.3"
version = "0.1.6"
edition = "2021"
license = "MIT"
license = "Apache-2.0"
readme = "README.md"


[workspace.dependencies]
async-trait = "0.1.77"
datafusion = "37.0.0"
datafusion-substrait = "37.0.0"
async-stream = "0.3.5"
futures = "0.3.30"
datafusion = "43"
datafusion-substrait = "43"
arrow-json = "53"
3 changes: 3 additions & 0 deletions datafusion-federation/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ path = "src/lib.rs"
[dependencies]
async-trait.workspace = true
datafusion.workspace = true
async-stream.workspace = true
futures.workspace = true
arrow-json.workspace = true

[package.metadata.docs.rs]

Expand Down
Loading