github.com/muhammadn/cortex@v1.9.1-0.20220510110439-46bb7000d03d/pkg/frontend/v1/frontendv1pb/frontend.proto (about) 1 syntax = "proto3"; 2 3 // Protobuf package should not be changed when moving around go packages 4 // in order to not break backward compatibility. 5 package frontend; 6 7 option go_package = "frontendv1pb"; 8 9 import "github.com/gogo/protobuf/gogoproto/gogo.proto"; 10 import "github.com/weaveworks/common/httpgrpc/httpgrpc.proto"; 11 import "github.com/cortexproject/cortex/pkg/querier/stats/stats.proto"; 12 13 option (gogoproto.marshaler_all) = true; 14 option (gogoproto.unmarshaler_all) = true; 15 16 service Frontend { 17 // After calling this method, client enters a loop, in which it waits for 18 // a "FrontendToClient" message and replies with single "ClientToFrontend" message. 19 rpc Process(stream ClientToFrontend) returns (stream FrontendToClient) {}; 20 21 // The client notifies the query-frontend that it started a graceful shutdown. 22 rpc NotifyClientShutdown(NotifyClientShutdownRequest) returns (NotifyClientShutdownResponse); 23 } 24 25 enum Type { 26 HTTP_REQUEST = 0; 27 GET_ID = 1; 28 } 29 30 message FrontendToClient { 31 httpgrpc.HTTPRequest httpRequest = 1; 32 Type type = 2; 33 34 // Whether query statistics tracking should be enabled. The response will include 35 // statistics only when this option is enabled. 36 bool statsEnabled = 3; 37 } 38 39 message ClientToFrontend { 40 httpgrpc.HTTPResponse httpResponse = 1; 41 string clientID = 2; 42 stats.Stats stats = 3; 43 } 44 45 message NotifyClientShutdownRequest { 46 string clientID = 1; 47 } 48 49 message NotifyClientShutdownResponse {}