apache / hudi-rs

A native Rust library for Apache Hudi, with bindings into Python

Home Page:https://hudi.apache.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

hudi-rs

codecov

Quick Start

Apache DataFusion

use std::sync::Arc;

use datafusion::error::Result;
use datafusion::prelude::{DataFrame, SessionContext};

use hudi_datafusion::HudiDataSource;

#[tokio::main]
async fn main() -> Result<()> {
    let ctx = SessionContext::new();
    let hudi = HudiDataSource::new("/tmp/trips_table");
    ctx.register_table("trips_table", Arc::new(hudi))?;
    let df: DataFrame = ctx.sql("SELECT * from trips_table where fare > 20.0").await?;
    df.show().await?;
    Ok(())
}

About

A native Rust library for Apache Hudi, with bindings into Python

https://hudi.apache.org/

License:Apache License 2.0


Languages

Language:Rust 97.4%Language:Makefile 2.6%