From 648f0d31a35e3e311057a421acaf3aeed42dce62 Mon Sep 17 00:00:00 2001 From: Dominik Moritz Date: Wed, 26 May 2021 13:20:04 -0700 Subject: [PATCH] Add crate badges (#362) * Add crate badges * Format markdown --- arrow-flight/README.md | 5 ++--- arrow/README.md | 2 ++ parquet/README.md | 16 ++++++++++++++++ 3 files changed, 20 insertions(+), 3 deletions(-) diff --git a/arrow-flight/README.md b/arrow-flight/README.md index ba63f65bc48f..4205ebb2e26b 100644 --- a/arrow-flight/README.md +++ b/arrow-flight/README.md @@ -19,11 +19,10 @@ # Apache Arrow Flight +[![Crates.io](https://img.shields.io/crates/v/arrow-flight.svg)](https://crates.io/crates/arrow-flight) + Apache Arrow Flight is a gRPC based protocol for exchanging Arrow data between processes. See the blog post [Introducing Apache Arrow Flight: A Framework for Fast Data Transport](https://arrow.apache.org/blog/2019/10/13/introducing-arrow-flight/) for more information. This crate simply provides the Rust implementation of the [Flight.proto](../../format/Flight.proto) gRPC protocol and provides an example that demonstrates how to build a Flight server implemented with Tonic. Note that building a Flight server also requires an implementation of Arrow IPC which is based on the Flatbuffers serialization framework. The Rust implementation of Arrow IPC is not yet complete although the generated Flatbuffers code is available as part of the core Arrow crate. - - - diff --git a/arrow/README.md b/arrow/README.md index 674c3fc6c8b2..e87350911807 100644 --- a/arrow/README.md +++ b/arrow/README.md @@ -19,6 +19,8 @@ # Native Rust implementation of Apache Arrow +[![Crates.io](https://img.shields.io/crates/v/arrow.svg)](https://crates.io/crates/arrow) + This crate contains a native Rust implementation of the [Arrow columnar format](https://arrow.apache.org/docs/format/Columnar.html). ## Developer's guide diff --git a/parquet/README.md b/parquet/README.md index 836a23bbc12d..d032fed7c32c 100644 --- a/parquet/README.md +++ b/parquet/README.md @@ -19,19 +19,25 @@ # An Apache Parquet implementation in Rust +[![Crates.io](https://img.shields.io/crates/v/parquet.svg)](https://crates.io/crates/parquet) + ## Usage + Add this to your Cargo.toml: + ```toml [dependencies] parquet = "5.0.0-SNAPSHOT" ``` and this to your crate root: + ```rust extern crate parquet; ``` Example usage of reading data: + ```rust use std::fs::File; use std::path::Path; @@ -44,6 +50,7 @@ while let Some(record) = iter.next() { println!("{}", record); } ``` + See [crate documentation](https://docs.rs/crate/parquet/5.0.0-SNAPSHOT) on available API. ## Upgrading from versions prior to 4.0 @@ -61,12 +68,14 @@ It is preferred that `LogicalType` is used, as it supports nanosecond precision timestamps without using the deprecated `Int96` Parquet type. ## Supported Parquet Version + - Parquet-format 2.6.0 To update Parquet format to a newer version, check if [parquet-format](https://github.com/sunchao/parquet-format-rs) version is available. Then simply update version of `parquet-format` crate in Cargo.toml. ## Features + - [X] All encodings supported - [X] All compression codecs supported - [X] Read support @@ -87,15 +96,18 @@ Parquet requires LLVM. Our windows CI image includes LLVM but to build the libr users will have to install LLVM. Follow [this](https://github.com/appveyor/ci/issues/2651) link for info. ## Build + Run `cargo build` or `cargo build --release` to build in release mode. Some features take advantage of SSE4.2 instructions, which can be enabled by adding `RUSTFLAGS="-C target-feature=+sse4.2"` before the `cargo build` command. ## Test + Run `cargo test` for unit tests. To also run tests related to the binaries, use `cargo test --features cli`. ## Binaries + The following binaries are provided (use `cargo install --features cli` to install them): - **parquet-schema** for printing Parquet file schema and metadata. `Usage: parquet-schema `, where `file-path` is the path to a Parquet file. Use `-v/--verbose` flag @@ -111,16 +123,20 @@ be printed). Use `-j/--json` to print records in JSON lines format. files to read. If you see `Library not loaded` error, please make sure `LD_LIBRARY_PATH` is set properly: + ``` export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(rustc --print sysroot)/lib ``` ## Benchmarks + Run `cargo bench` for benchmarks. ## Docs + To build documentation, run `cargo doc --no-deps`. To compile and view in the browser, run `cargo doc --no-deps --open`. ## License + Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0.