Skip to content

Protocol Documentation

Table of Contents

Top

deepproto/proto/poll/v1/poll.proto

PollRequest

PollRequest is sent by the client to check its current config with the server.

Field Type Label Description
ts_nanos fixed64 The time (as epoch nanos) when the message was sent, acts as message ID.
current_hash string This should the the hash that was last sent by the server, this is used to determine if the config has changed since the last poll. If no hash is available (e.g. first poll) then do not set this value.
resource deepproto.proto.resource.v1.Resource The attributes that represent the client making the request. These attributes are used to filter the tracepoint response to just the tracepoints that are for the requesting client.

PollResponse

PollResponse is the response the server will send in response to a PollRequest.

Field Type Label Description
ts_nanos fixed64 The time (as epoch nanos) then he message was sent. This should match the 'ts_nanos' from the triggering PollRequest.
current_hash string This is the hash that the server has assigned this current config for this client. This should be sent with the next PollRequest.
response deepproto.proto.tracepoint.v1.TracePointConfig repeated This is the list of tracepoints that are currently configured for this client.
response_type ResponseType This indicates if the config has changed or not. If 'NO_CHANGE' then 'response' should be null or empty.

ResponseType

ResponseType is used to indicate if the response from the server should trigger an update of the client config. If the client sends the same 'current_hash' as that which the server has for the client, then the server will response with 'NO_CHANGE'. This allows the client to not trigger any changes to the current tracepoint configs.

Name Number Description
NO_CHANGE 0 This is sent when the 'current_hash' from the request is the same as the response. So the client should do nothing.
UPDATE 1 This is sent when the client should process the response to update the config.

PollConfig

This is how the application agent should request the config of the tracepoints.

Method Name Request Type Response Type Description
poll PollRequest PollResponse Call this function as often as is required to ensure config is up to date.

Scalar Value Types

.proto Type Notes C++ Java Python Go C# PHP Ruby
double double double float float64 double float Float
float float float float float32 float float Float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int int32 int integer Bignum or Fixnum (as required)
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long int64 long integer/string Bignum
uint32 Uses variable-length encoding. uint32 int int/long uint32 uint integer Bignum or Fixnum (as required)
uint64 Uses variable-length encoding. uint64 long int/long uint64 ulong integer/string Bignum or Fixnum (as required)
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int int32 int integer Bignum or Fixnum (as required)
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long int64 long integer/string Bignum
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int uint32 uint integer Bignum or Fixnum (as required)
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long uint64 ulong integer/string Bignum
sfixed32 Always four bytes. int32 int int int32 int integer Bignum or Fixnum (as required)
sfixed64 Always eight bytes. int64 long int/long int64 long integer/string Bignum
bool bool boolean boolean bool bool boolean TrueClass/FalseClass
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode string string string String (UTF-8)
bytes May contain any arbitrary sequence of bytes. string ByteString str []byte ByteString string String (ASCII-8BIT)