Merge pull request #8627 from influxdata/savage/define-get-tables-request-rpc

feat(proto): Define GetTables RPC for TableService
pull/24376/head
kodiakhq[bot] 2023-08-31 11:54:27 +00:00 committed by GitHub
commit 5b48b4983b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 21 additions and 0 deletions

View File

@ -5,6 +5,9 @@ option go_package = "github.com/influxdata/iox/table/v1";
import "influxdata/iox/partition_template/v1/template.proto";
service TableService {
// Get tables within a namespace
rpc GetTables(GetTablesRequest) returns (GetTablesResponse);
// Create a table in a namespace
rpc CreateTable(CreateTableRequest) returns (CreateTableResponse);
}
@ -41,3 +44,13 @@ message Table {
// The partitioning scheme applied to writes for this table
influxdata.iox.partition_template.v1.PartitionTemplate partition_template = 4;
}
message GetTablesRequest {
// Name of the namespace to list tables for.
string namespace_name = 1;
}
message GetTablesResponse {
// Tables contained within the namespace.
repeated Table tables = 1;
}

View File

@ -48,6 +48,14 @@ impl TableService {
#[tonic::async_trait]
impl table_service_server::TableService for TableService {
// List tables for a namespace
async fn get_tables(
&self,
_request: Request<GetTablesRequest>,
) -> Result<Response<GetTablesResponse>, Status> {
Err(tonic::Status::unimplemented("not yet implemented"))
}
// create a table
async fn create_table(
&self,