Merge pull request #5462 from influxdata/dom/update-shardservice-grpc

refactor(proto): update ShardService gRPC defintion
pull/24376/head
kodiakhq[bot] 2022-08-24 09:51:05 +00:00 committed by GitHub
commit af9a68a853
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 17 additions and 10 deletions

View File

@ -26,6 +26,7 @@ fn main() -> Result<()> {
/// - `influxdata.iox.predicate.v1.rs`
/// - `influxdata.iox.querier.v1.rs`
/// - `influxdata.iox.schema.v1.rs`
/// - `influxdata.iox.sharder.v1.rs`
/// - `influxdata.iox.write.v1.rs`
/// - `influxdata.iox.write_buffer.v1.rs`
/// - `influxdata.platform.storage.rs`
@ -38,6 +39,7 @@ fn generate_grpc_types(root: &Path) -> Result<()> {
let predicate_path = root.join("influxdata/iox/predicate/v1");
let querier_path = root.join("influxdata/iox/querier/v1");
let schema_path = root.join("influxdata/iox/schema/v1");
let sharder_path = root.join("influxdata/iox/sharder/v1");
let write_buffer_path = root.join("influxdata/iox/write_buffer/v1");
let write_summary_path = root.join("influxdata/iox/write_summary/v1");
let storage_path = root.join("influxdata/platform/storage");
@ -59,6 +61,7 @@ fn generate_grpc_types(root: &Path) -> Result<()> {
root.join("grpc/health/v1/service.proto"),
root.join("influxdata/pbdata/v1/influxdb_pb_data_protocol.proto"),
schema_path.join("service.proto"),
sharder_path.join("sharder.proto"),
write_buffer_path.join("write_buffer.proto"),
write_summary_path.join("write_summary.proto"),
storage_path.join("predicate.proto"),

View File

@ -10,17 +10,11 @@ service ShardService {
message ShardToSequencerIdRequest {
// The shard input values to map onto a Sequencer.
oneof input {
// A table & namespace pair.
TableNamespaceTuple table_namespace = 1;
}
string table_name = 1;
string namespace_name = 2;
}
message ShardToSequencerIdResponse {
uint64 sequencer_id = 1;
}
message TableNamespaceTuple {
string table = 1;
string namespace = 2;
int64 sequencer_id = 1;
int32 sequencer_index = 2;
}

View File

@ -140,6 +140,16 @@ pub mod influxdata {
}
}
pub mod sharder {
pub mod v1 {
include!(concat!(env!("OUT_DIR"), "/influxdata.iox.sharder.v1.rs"));
include!(concat!(
env!("OUT_DIR"),
"/influxdata.iox.sharder.v1.serde.rs"
));
}
}
pub mod write_buffer {
pub mod v1 {
include!(concat!(