add proto file

This commit is contained in:
Martin Ptáček
2023-06-01 21:40:47 +02:00
parent c0cdae89ec
commit 30b58c6227
2 changed files with 29 additions and 1 deletions

View File

@ -5,6 +5,7 @@ data class RemoteWriteConfiguration(
val remote_write_endpoint : String,
)
class RemoteWrite {
class RemoteWrite(config : RemoteWriteConfiguration) {
//TODO implement this thing
}

27
remote-write.proto Normal file
View File

@ -0,0 +1,27 @@
syntax = "proto3";
message WriteRequest {
repeated TimeSeries timeseries = 1;
// Cortex uses this field to determine the source of the write request.
// We reserve it to avoid any compatibility issues.
reserved 2;
// Prometheus uses this field to send metadata, but this is
// omitted from v1 of the spec as it is experimental.
reserved 3;
}
message TimeSeries {
repeated Label labels = 1;
repeated Sample samples = 2;
}
message Label {
string name = 1;
string value = 2;
}
message Sample {
double value = 1;
int64 timestamp = 2;
}