Rust Client for TiKV

Nick Cameron 3908c6a1f9 Merge pull request #118 from nrc/retry 1 week ago
examples f093c64f21 Upgrade toolchain and dependencies. 3 weeks ago
src d5a6345b06 Merge branch 'master' into retry 1 week ago
tests f093c64f21 Upgrade toolchain and dependencies. 3 weeks ago
.gitignore d8c604394f Add gitignore 10 months ago
.travis.yml 52ea5dd600 Fix CI by changing PD_ADDR to PD_ADDRS 1 month ago
Cargo.toml 4f6cecc18c Remove tokio-timer 3 weeks ago
LICENSE db5d4ef3ca Initial commit 1 year ago f093c64f21 Upgrade toolchain and dependencies. 3 weeks ago
rust-toolchain f093c64f21 Upgrade toolchain and dependencies. 3 weeks ago

TiKV Client (Rust)

Build Status Documentation

Currently this crate is experimental and some portions (e.g. the Transactional API) are still in active development. You're encouraged to use this library for testing and to help us find problems!

This crate provides a clean, ready to use client for TiKV, a distributed transactional Key-Value database written in Rust.

With this crate you can easily connect to any TiKV deployment, interact with it, and mutate the data it contains.

This is an open source (Apache 2) project hosted by the Cloud Native Computing Foundation (CNCF) and maintained by the TiKV Authors. We'd love it if you joined us in improving this project.

Using the client

The TiKV client is a Rust library (crate). It uses async/await internally and exposes some async fn APIs as well.

Async/await is a new feature in Rust and cannot be used with a stable Rust compiler. To use it now you'll need to use Rust 1.39 (see below).

To use this crate in your project, add it as a dependency in your Cargo.toml:

# ...Your other dependencies...
tikv-client = { git = "" }

The client requires a Git dependency until we can publish it.

There are examples which show how to use the client in a Rust program.

Access the documentation

We recommend using the cargo-generated documentation to browse and understand the API. We've done our best to include ample, tested, and understandable examples.

You can visit, or build the documentation yourself.

You can access the documentation on your machine by running the following in any project that depends on tikv-client.

cargo doc --package tikv-client --open
# If it didn't work, browse file URL it tried to open with your browser.

Toolchain versions

To check what version of Rust you are using, run

rustc --version

You'll see something like rustc 1.39.0-nightly (eeba189cf 2019-08-24) where the 1.39.0 is the toolchain version, and nightly is the channel (stable/beta/nightly). To install another toolchain use

rustup toolchain install nightly

Where nightly here is the channel to add. To update your toolchains, run

rustup update

To build your project using a specified toolchain, use something like

cargo +nightly build

Where nightly names the toolchain (by specifying the channel, in this case).