From c443373859d6d19df559fbff269da462ba563e4b Mon Sep 17 00:00:00 2001 From: "data-plane-api(CircleCI)" Date: Wed, 23 May 2018 20:02:51 +0000 Subject: [PATCH] format: run clang-format on proto files (#3473) Signed-off-by: Matt Klein Mirrored from https://github.com/envoyproxy/envoy @ 033beaaa0e5b3b685b2de323bac070516d7700c3 --- envoy/api/v2/auth/cert.proto | 2 +- envoy/api/v2/listener/listener.proto | 18 ++++++------ envoy/api/v2/route/route.proto | 18 ++++++------ .../http/transcoder/v2/transcoder.proto | 2 +- envoy/config/rbac/v2alpha/rbac.proto | 28 ++++++++++--------- envoy/type/string_match.proto | 3 +- 6 files changed, 38 insertions(+), 33 deletions(-) diff --git a/envoy/api/v2/auth/cert.proto b/envoy/api/v2/auth/cert.proto index e2e355c2..40524afe 100644 --- a/envoy/api/v2/auth/cert.proto +++ b/envoy/api/v2/auth/cert.proto @@ -147,7 +147,7 @@ message CertificateValidationContext { // // Both of those formats are acceptable. repeated string verify_certificate_hash = 2 - [(validate.rules).repeated.items.string = {min_bytes: 64, max_bytes: 95}]; + [(validate.rules).repeated .items.string = {min_bytes: 64, max_bytes: 95}]; // If specified, Envoy will verify (pin) base64-encoded SHA-256 hash of // the Subject Public Key Information (SPKI) of the presented certificate. diff --git a/envoy/api/v2/listener/listener.proto b/envoy/api/v2/listener/listener.proto index d7e48188..f9436c24 100644 --- a/envoy/api/v2/listener/listener.proto +++ b/envoy/api/v2/listener/listener.proto @@ -102,8 +102,8 @@ message FilterChainMatch { google.protobuf.UInt32Value destination_port = 8; // If non-empty, a list of server names (e.g. SNI for TLS protocol) to consider when determining - // a filter chain match. Those values will be compared against the server names of a new connection, - // when detected by one of the listener filters. + // a filter chain match. Those values will be compared against the server names of a new + // connection, when detected by one of the listener filters. // // The server name will be matched against all wildcard domains, i.e. ``www.example.com`` // will be first matched against ``www.example.com``, then ``*.example.com``, then ``*.com``. @@ -128,12 +128,13 @@ message FilterChainMatch { string transport_protocol = 9; // If non-empty, a list of application protocols (e.g. ALPN for TLS protocol) to consider when - // determining a filter chain match. Those values will be compared against the application protocols - // of a new connection, when detected by one of the listener filters. + // determining a filter chain match. Those values will be compared against the application + // protocols of a new connection, when detected by one of the listener filters. // // Suggested values include: // - // * ``http/1.1`` - set by :ref:`envoy.listener.tls_inspector `, + // * ``http/1.1`` - set by :ref:`envoy.listener.tls_inspector + // `, // * ``h2`` - set by :ref:`envoy.listener.tls_inspector ` // // .. attention:: @@ -148,8 +149,8 @@ message FilterChainMatch { repeated string application_protocols = 10; // If non-empty, a list of server names (e.g. SNI for TLS protocol) to consider when determining - // a filter chain match. Those values will be compared against the server names of a new connection, - // when detected by one of the listener filters. + // a filter chain match. Those values will be compared against the server names of a new + // connection, when detected by one of the listener filters. // // The server name will be matched against all wildcard domains, i.e. ``www.example.com`` // will be first matched against ``www.example.com``, then ``*.example.com``, then ``*.com``. @@ -158,7 +159,8 @@ message FilterChainMatch { // // .. attention:: // - // Deprecated. Use :ref:`server_names ` instead. + // Deprecated. Use :ref:`server_names ` + // instead. repeated string sni_domains = 1 [deprecated = true]; } diff --git a/envoy/api/v2/route/route.proto b/envoy/api/v2/route/route.proto index 68e3b717..7ae95163 100644 --- a/envoy/api/v2/route/route.proto +++ b/envoy/api/v2/route/route.proto @@ -570,23 +570,25 @@ message RouteAction { google.protobuf.BoolValue use_websocket = 16; message WebSocketProxyConfig { - // See :ref:`stat_prefix `. - // If the parameter is not specified, the default value of "websocket" is used. + // See :ref:`stat_prefix + // `. If the parameter + // is not specified, the default value of "websocket" is used. // // WebSocket connections support the :ref:`downstream statistics - // ` for TCP proxy, except for the following, which are reported - // in the :ref:`HTTP Connection Manager statistics `: + // ` for TCP proxy, except for the following, which are + // reported in the :ref:`HTTP Connection Manager statistics `: // - downstream_cx_tx_bytes_total // - downstream_cx_tx_bytes_buffered // - downstream_cx_rx_bytes_total // - downstream_cx_rx_bytes_buffered string stat_prefix = 1; - // See :ref:`idle_timeout `. - // This timeout is only in effect after the WebSocket upgrade request is received by Envoy. It does - // not cover the initial part of the HTTP request. + // See :ref:`idle_timeout + // `. This timeout is + // only in effect after the WebSocket upgrade request is received by Envoy. It does not cover + // the initial part of the HTTP request. google.protobuf.Duration idle_timeout = 2 - [(validate.rules).duration.gt = {}, (gogoproto.stdduration) = true]; + [(validate.rules).duration.gt = {}, (gogoproto.stdduration) = true]; // See :ref:`max_connect_attempts // `. diff --git a/envoy/config/filter/http/transcoder/v2/transcoder.proto b/envoy/config/filter/http/transcoder/v2/transcoder.proto index e624f718..67d14ac8 100644 --- a/envoy/config/filter/http/transcoder/v2/transcoder.proto +++ b/envoy/config/filter/http/transcoder/v2/transcoder.proto @@ -26,7 +26,7 @@ message GrpcJsonTranscoder { // A list of strings that // supplies the fully qualified service names (i.e. "package_name.service_name") that // the transcoder will translate. If the service name doesn't exist in ``proto_descriptor``, - // Envoy will fail at startup. The ``proto_descriptor`` may contain more services than + // Envoy will fail at startup. The ``proto_descriptor`` may contain more services than // the service names specified here, but they won't be translated. repeated string services = 2 [(validate.rules).repeated .min_items = 1]; diff --git a/envoy/config/rbac/v2alpha/rbac.proto b/envoy/config/rbac/v2alpha/rbac.proto index 82b59b19..1783e0a3 100644 --- a/envoy/config/rbac/v2alpha/rbac.proto +++ b/envoy/config/rbac/v2alpha/rbac.proto @@ -7,18 +7,20 @@ import "envoy/type/string_match.proto"; package envoy.config.rbac.v2alpha; option go_package = "v2alpha"; -// Role Based Access Control (RBAC) provides service-level and method-level access control for a service. -// The RBAC engine authorizes a request by evaluating the request context (expressed in the form of -// :ref: `AttributeContext `) against the RBAC policies. +// Role Based Access Control (RBAC) provides service-level and method-level access control for a +// service. The RBAC engine authorizes a request by evaluating the request context (expressed in the +// form of :ref: `AttributeContext `) against +// the RBAC policies. // -// RBAC policies are additive. The policies are examined in order. A request is allowed once a matching policy -// is found (suppose the `action` is ALLOW). +// RBAC policies are additive. The policies are examined in order. A request is allowed once a +// matching policy is found (suppose the `action` is ALLOW). // // Here is an example of RBAC configuration. It has two policies: -// * Service account "cluster.local/ns/default/sa/admin" has full access (empty permission entry means full access) -// to the service. -// * Any user (empty principal entry means any user) can read ("GET") the service at paths with prefix "/products" or -// suffix "/reviews" when request header "version" set to either "v1" or "v2". +// * Service account "cluster.local/ns/default/sa/admin" has full access (empty permission entry +// means full access) to the service. +// * Any user (empty principal entry means any user) can read ("GET") the service at paths with +// prefix "/products" or suffix "/reviews" when request header "version" set to either "v1" or +// "v2". // // action: ALLOW // policies: @@ -59,11 +61,11 @@ message RBAC { // Policy specifies a role and the principals that are assigned/denied the role. message Policy { - // Required. The set of permissions that define a role. - repeated Permission permissions = 1 [(validate.rules).repeated .min_items = 1]; + // Required. The set of permissions that define a role. + repeated Permission permissions = 1 [(validate.rules).repeated .min_items = 1]; - // Required. List of principals that are assigned/denied the role based on “action”. - repeated Principal principals = 2 [(validate.rules).repeated .min_items = 1]; + // Required. List of principals that are assigned/denied the role based on “action”. + repeated Principal principals = 2 [(validate.rules).repeated .min_items = 1]; } // Specifies how to match an entry in a map. diff --git a/envoy/type/string_match.proto b/envoy/type/string_match.proto index 21c54bf5..c1e2468a 100644 --- a/envoy/type/string_match.proto +++ b/envoy/type/string_match.proto @@ -26,6 +26,5 @@ message StringMatch { // The regex grammar is defined `here // `_. string regex = 4; - } + } } -