refactor: remove redudant PromStoreProtocolHandler::write (#3553)

refactor: remove redudant PromStoreProtocolHandler::write API and rename PromStoreProtocolHandler::write_fast to write
This commit is contained in:
Lei, HUANG
2024-03-22 10:09:00 +08:00
committed by GitHub
parent 1f0fc40287
commit 86fb9d8ac7
9 changed files with 46 additions and 99 deletions

View File

@@ -58,16 +58,7 @@ impl GrpcQueryHandler for DummyInstance {
#[async_trait]
impl PromStoreProtocolHandler for DummyInstance {
async fn write(&self, request: WriteRequest, ctx: QueryContextRef, _: bool) -> Result<Output> {
let _ = self
.tx
.send((ctx.current_schema().to_owned(), request.encode_to_vec()))
.await;
Ok(Output::new_with_affected_rows(0))
}
async fn write_fast(
async fn write(
&self,
_request: RowInsertRequests,
_ctx: QueryContextRef,