mirror of
https://github.com/qdrant/qdrant.git
synced 2026-09-25 15:37:42 -05:00
* Add routing token structure * Implement routing token in read operation executor as per design doc * Add TODO to glue routing token to user requests * Implement routing header for REST API * Source routing token from request, not from JWT token * Implement routing token in gRPC API * Add test * Review remarks Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * Use lower case header name to prevent panic * Rename header to X-Qdrant-Route-Affinity * Assert routing consistency in test on all peers --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
11 lines
411 B
Rust
11 lines
411 B
Rust
pub mod conversions;
|
|
pub mod grpc;
|
|
pub mod rest;
|
|
|
|
pub const HTTP_HEADER_API_KEY: &str = "api-key";
|
|
|
|
/// HTTP header / gRPC metadata key carrying the optional deterministic read
|
|
/// routing token. Requests sharing the same value are consistently routed to the
|
|
/// same shard replicas, avoiding "blinking" results caused by deferred updates.
|
|
pub const HTTP_HEADER_ROUTING_TOKEN: &str = "x-qdrant-route-affinity";
|