1 stable release
1.4.0 | Aug 7, 2023 |
---|
#235 in Database implementations
355KB
7.5K
SLoC
arc-vector-rust
Rust client for arc vector search engine.
Installation
cargo add arc-vector-rust
Or add the following line to your Cargo.toml:
arc-vector-rust = "1.4.0"
Package is available in crates.io
Dependencies
The client uses gRPC via the Tonic library.
To change anything in the protocol buffer definitions, you need the protoc
Protocol Buffers compiler, along with Protocol Buffers resource files.
Refer to the Tonic installation guide for more details.
Usage
Run ArcVector with enabled gRPC interface:
# With env variable
docker run -p 6333:6333 -p 6334:6334 \
-e ARC_VECTOR__SERVICE__GRPC_PORT="6334" \
arc_vector/arc_vector
Or by updating the configuration file:
service:
grpc_port: 6334
More info about gRPC in documentation.
Making requests
Add necessary dependencies:
cargo arc-vector-rust anyhow tonic tokio --features tokio/rt-multi-thread
Add search example from examples/search.rs
to your src/main.rs
:
Or run the example from this project directly:
cargo run --example search
Dependencies
~12–25MB
~466K SLoC