Busabase
Busabase 是一个开源(MIT)数据库与 AI 智能体工作空间——将数据、文档、技能和应用集成于一体。您可以本地运行、在网络内自托管或使用 Busabase Cloud,从而开启新时代。
AI 翻译
Apache DataFusion Ballista Distributed Query Engine
翻译准备中
数据Rust · PythonGitHub @apache自行安装运营者未确认
试用过了吗? 点一下就好,无需登录。
制作者的介绍仅有上面的一句话。 更多详情请阅读仓库 README。 仓库 README ↗
正在加载完整 README。
查看完整 README ↗Ballista is a distributed query execution engine that enhances Apache DataFusion by enabling the parallelized execution of workloads across multiple nodes in a distributed environment.
It is also a lighter, Rust-native alternative to Apache Spark, keeping the same execution model of stages, shuffles and adaptive query execution. On a 1 TB benchmark derived from TPC-H, Ballista is 2.2x faster than Spark by default and 3.4x faster with experimental pipelined execution.
An existing DataFusion application can be distributed with a few lines of code changed:
+use ballista::prelude::*;
use datafusion::prelude::*;
#[tokio::main]
async fn main() -> datafusion::error::Result<()> {
- let ctx = SessionContext::new();
+ // create SessionContext with ballista support
+ // standalone context will start all required
+ // ballista infrastructure in the background as well
+ let ctx = SessionContext::standalone().await?;
// register the table
ctx.register_csv("example", "tests/data/example.csv", CsvReadOptions::new())
.await?;
// create a plan to run a SQL query
let df = ctx
.sql("SELECT a, MIN(b) FROM example WHERE a <= b GROUP BY a LIMIT 100")
.await?;
// execute and print results
df.show().await?;
Ok(())
}
For documentation or more examples, please refer to the Ballista User Guide.
Ballista is measured against Apache Spark 4.1.3 on the same cluster shape: Kubernetes on AWS, with 32 executors of 8 vCPUs running the 22 queries over 1 TB of Parquet in S3. Each Ballista executor had 64 GiB of memory, and each Spark executor 74 GiB.
Derived from TPC-H and not an official TPC-H result. Times are the mean of two runs, including the cold first run. The Spark numbers come from an earlier run with separate scripts and its own phrasing of the queries. See the benchmarking guide for versions, settings, the full results and how to reproduce them.
DataFrame.cache() keeps intermediate results on the executors for reuse within a session (opt-in)Ballista serves several distinct audiences:
以上为 README 的开头部分。其余内容请阅读原文。 查看完整 README ↗