Crates.io | pachyderm |
lib.rs | pachyderm |
version | 0.4.1 |
source | src |
created_at | 2019-11-18 18:22:14.082351 |
updated_at | 2020-08-06 14:41:07.60212 |
description | The official Pachyderm Rust library |
homepage | https://pachyderm.io |
repository | https://github.com/pachyderm/rust-pachyderm |
max_upload_size | |
id | 182261 |
size | 418,580 |
Official Rust Pachyderm client. This library provides low-level (auto-generated) bindings to our gRPC services, with support for async/await thanks to tonic. It should work on rust stable 1.39+, as well as nightly/beta.
Here's an example that creates a repo and adds a file:
//! This creates a PFS repo called `hello-world`
extern crate pachyderm;
extern crate tokio;
extern crate tonic;
use std::error::Error;
use pachyderm::pfs::{client::ApiClient as PfsClient, CreateRepoRequest, Repo};
#[tokio::main]
async fn main() -> Result<(), Box<dyn Error>> {
let mut client = PfsClient::connect("http://localhost:30650").await?;
let request = tonic::Request::new(CreateRepoRequest {
repo: Some(Repo {
name: "hello-world".into()
}),
description: "".into(),
update: false
});
let response = client.create_repo(request).await?;
println!("Response: {:?}", response);
Ok(())
}
Hello World: Creates a PFS repo called hello-world
. To run: cargo run --example hello_world
OpenCV: This is the canonical Pachyderm/OpenCV demo, ported to this library. To run cargo run --example opencv
This driver is co-maintained by Pachyderm and the community. If you're looking to contribute to the project, this is a fantastic place to get involved. Take a look at the contributing guide for more info.