TraceSegmentService.proto 1.3 KB
Newer Older
wu-sheng's avatar
wu-sheng 已提交
1 2 3
syntax = "proto3";

option java_multiple_files = true;
wu-sheng's avatar
wu-sheng 已提交
4
option java_package = "org.skywalking.apm.network.trace.proto";
wu-sheng's avatar
wu-sheng 已提交
5

wu-sheng's avatar
wu-sheng 已提交
6 7
import "Downstream.proto";

wu-sheng's avatar
wu-sheng 已提交
8
service TraceSegmentService {
9
    rpc collect (stream TraceSegmentObject) returns (Downstream) {
wu-sheng's avatar
wu-sheng 已提交
10 11 12 13
    }
}

message TraceSegmentObject {
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
    string traceSegmentId = 1;
    repeated TraceSegmentReference refs = 2;
    repeated SpanObject spans = 3;
    int32 applicationId = 4;
    repeated string globalTraceIds = 5;
}

message TraceSegmentReference {
    string parentTraceSegmentId = 1;
    int32 parentSpanId = 2;
    repeated int32 serviceChains = 3;
    int32 parentApplicationId = 4;
    int32 networkAddressId = 5;
}

message SpanObject {
    int32 spanId = 1;
    int32 parentSpanId = 2;
    int64 startTime = 3;
    int64 endTime = 4;
    int32 operationNameId = 5;
    int32 peerNetworkAddressId = 6;
    SpanType spanType = 7;
    SpanLayer spanLayer = 8;
    string component = 9;
    bool isError = 10;
    repeated KeyValue tags = 11;
    repeated LogMessage logs = 12;
}

enum SpanType {
    Entry = 0;
    Exit = 1;
    Local = 2;
}

enum SpanLayer {
    Database = 0;
    RPCFramework = 1;
    Http = 2;
}

message KeyValue {
    string key = 1;
    string value = 2;
}

message LogMessage {
    int64 time = 1;
    repeated KeyValue data = 2;
wu-sheng's avatar
wu-sheng 已提交
64
}