als.proto 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. syntax = "proto3";
  2. package envoy.extensions.access_loggers.grpc.v3;
  3. import "envoy/config/core/v3/base.proto";
  4. import "envoy/config/core/v3/config_source.proto";
  5. import "envoy/config/core/v3/grpc_service.proto";
  6. import "envoy/type/tracing/v3/custom_tag.proto";
  7. import "google/protobuf/duration.proto";
  8. import "google/protobuf/wrappers.proto";
  9. import "udpa/annotations/status.proto";
  10. import "udpa/annotations/versioning.proto";
  11. import "validate/validate.proto";
  12. option java_package = "io.envoyproxy.envoy.extensions.access_loggers.grpc.v3";
  13. option java_outer_classname = "AlsProto";
  14. option java_multiple_files = true;
  15. option go_package = "github.com/envoyproxy/go-control-plane/envoy/extensions/access_loggers/grpc/v3;grpcv3";
  16. option (udpa.annotations.file_status).package_version_status = ACTIVE;
  17. // [#protodoc-title: gRPC Access Log Service (ALS)]
  18. // Configuration for the built-in *envoy.access_loggers.http_grpc*
  19. // :ref:`AccessLog <envoy_v3_api_msg_config.accesslog.v3.AccessLog>`. This configuration will
  20. // populate :ref:`StreamAccessLogsMessage.http_logs
  21. // <envoy_v3_api_field_service.accesslog.v3.StreamAccessLogsMessage.http_logs>`.
  22. // [#extension: envoy.access_loggers.http_grpc]
  23. message HttpGrpcAccessLogConfig {
  24. option (udpa.annotations.versioning).previous_message_type =
  25. "envoy.config.accesslog.v2.HttpGrpcAccessLogConfig";
  26. CommonGrpcAccessLogConfig common_config = 1 [(validate.rules).message = {required: true}];
  27. // Additional request headers to log in :ref:`HTTPRequestProperties.request_headers
  28. // <envoy_v3_api_field_data.accesslog.v3.HTTPRequestProperties.request_headers>`.
  29. repeated string additional_request_headers_to_log = 2;
  30. // Additional response headers to log in :ref:`HTTPResponseProperties.response_headers
  31. // <envoy_v3_api_field_data.accesslog.v3.HTTPResponseProperties.response_headers>`.
  32. repeated string additional_response_headers_to_log = 3;
  33. // Additional response trailers to log in :ref:`HTTPResponseProperties.response_trailers
  34. // <envoy_v3_api_field_data.accesslog.v3.HTTPResponseProperties.response_trailers>`.
  35. repeated string additional_response_trailers_to_log = 4;
  36. }
  37. // Configuration for the built-in *envoy.access_loggers.tcp_grpc* type. This configuration will
  38. // populate *StreamAccessLogsMessage.tcp_logs*.
  39. // [#extension: envoy.access_loggers.tcp_grpc]
  40. message TcpGrpcAccessLogConfig {
  41. option (udpa.annotations.versioning).previous_message_type =
  42. "envoy.config.accesslog.v2.TcpGrpcAccessLogConfig";
  43. CommonGrpcAccessLogConfig common_config = 1 [(validate.rules).message = {required: true}];
  44. }
  45. // Common configuration for gRPC access logs.
  46. // [#next-free-field: 9]
  47. message CommonGrpcAccessLogConfig {
  48. option (udpa.annotations.versioning).previous_message_type =
  49. "envoy.config.accesslog.v2.CommonGrpcAccessLogConfig";
  50. // The friendly name of the access log to be returned in :ref:`StreamAccessLogsMessage.Identifier
  51. // <envoy_v3_api_msg_service.accesslog.v3.StreamAccessLogsMessage.Identifier>`. This allows the
  52. // access log server to differentiate between different access logs coming from the same Envoy.
  53. string log_name = 1 [(validate.rules).string = {min_len: 1}];
  54. // The gRPC service for the access log service.
  55. config.core.v3.GrpcService grpc_service = 2 [(validate.rules).message = {required: true}];
  56. // API version for access logs service transport protocol. This describes the access logs service
  57. // gRPC endpoint and version of messages used on the wire.
  58. config.core.v3.ApiVersion transport_api_version = 6
  59. [(validate.rules).enum = {defined_only: true}];
  60. // Interval for flushing access logs to the gRPC stream. Logger will flush requests every time
  61. // this interval is elapsed, or when batch size limit is hit, whichever comes first. Defaults to
  62. // 1 second.
  63. google.protobuf.Duration buffer_flush_interval = 3 [(validate.rules).duration = {gt {}}];
  64. // Soft size limit in bytes for access log entries buffer. Logger will buffer requests until
  65. // this limit it hit, or every time flush interval is elapsed, whichever comes first. Setting it
  66. // to zero effectively disables the batching. Defaults to 16384.
  67. google.protobuf.UInt32Value buffer_size_bytes = 4;
  68. // Additional filter state objects to log in :ref:`filter_state_objects
  69. // <envoy_v3_api_field_data.accesslog.v3.AccessLogCommon.filter_state_objects>`.
  70. // Logger will call `FilterState::Object::serializeAsProto` to serialize the filter state object.
  71. repeated string filter_state_objects_to_log = 5;
  72. // Sets the retry policy when the establishment of a gRPC stream fails.
  73. // If the stream succeeds once in establishing If the stream succeeds
  74. // at least once in establishing itself, no retry will be performed
  75. // no matter what gRPC status is received. Note that only
  76. // :ref:`num_retries <envoy_v3_api_field_config.core.v3.RetryPolicy.num_retries>`
  77. // will be used in this configuration. This feature is used only when you are using
  78. // :ref:`Envoy gRPC client <envoy_v3_api_field_config.core.v3.GrpcService.envoy_grpc>`.
  79. config.core.v3.RetryPolicy grpc_stream_retry_policy = 7;
  80. // A list of custom tags with unique tag name to create tags for the logs.
  81. repeated type.tracing.v3.CustomTag custom_tags = 8;
  82. }