github.com/google/cloudprober@v0.11.3/probes/http/proto/config.proto (about)

     1  syntax = "proto2";
     2  
     3  package cloudprober.probes.http;
     4  
     5  import "github.com/google/cloudprober/common/oauth/proto/config.proto";
     6  import "github.com/google/cloudprober/common/tlsconfig/proto/config.proto";
     7  
     8  option go_package = "github.com/google/cloudprober/probes/http/proto";
     9  
    10  // Next tag: 17
    11  message ProbeConf {
    12    enum ProtocolType {
    13      HTTP = 0;
    14      HTTPS = 1;
    15    }
    16  
    17    enum Method {
    18      GET = 0;
    19      POST = 1;
    20      PUT = 2;
    21      HEAD = 3;
    22      DELETE = 4;
    23      PATCH = 5;
    24      OPTIONS = 6;
    25    }
    26  
    27    message Header {
    28      optional string name = 1;
    29      optional string value = 2;
    30    }
    31  
    32    // Which HTTP protocol to use
    33    optional ProtocolType protocol = 1 [default = HTTP];
    34    // Relative URL (to append to all targets). Must begin with '/'
    35    optional string relative_url = 2;
    36    // Port for HTTP requests. If not specfied, port is selected in the following
    37    // order:
    38    //  - If port is provided by the targets (e.g. kubernetes endpoint or
    39    //    service), that port is used.
    40    //  - 80 for HTTP and 443 for HTTPS.
    41    optional int32 port = 3;
    42  
    43    // Whether to resolve the target before making the request. If set to false,
    44    // we hand over the target and relative_url directly to the golang's HTTP
    45    // module, Otherwise, we resolve the target first to an IP address and
    46    // make a request using that while passing target name as Host header.
    47    optional bool resolve_first = 4 [default = false];
    48  
    49    // Export response (body) count as a metric
    50    optional bool export_response_as_metrics = 5 [default = false];
    51  
    52    // HTTP request method
    53    optional Method method = 7 [default = GET];
    54  
    55    // HTTP request headers
    56    repeated Header headers = 8;
    57  
    58    // Request body.
    59    optional string body = 9;
    60  
    61    // Enable HTTP keep-alive. If set to true, underlying connection is reused
    62    // for further probes. Default is to close the connection after every request.
    63    optional bool keep_alive = 10;
    64  
    65    // OAuth Config
    66    optional oauth.Config oauth_config = 11;
    67  
    68    // Disable HTTP2
    69    // Golang HTTP client automatically enables HTTP/2 if server supports it. This
    70    // option disables that behavior to enforce HTTP/1.1 for testing purpose.
    71    optional bool disable_http2 = 13;
    72  
    73    // Disable TLS certificate validation. If set to true, any certificate
    74    // presented by the server for any host name will be accepted
    75    // Deprecation: This option is now subsumed by the tls_config below. To
    76    // disable cert validation use:
    77    // tls_config {
    78    //   disable_cert_validation: true
    79    // }
    80    optional bool disable_cert_validation = 14;
    81  
    82    // TLS config
    83    optional tlsconfig.TLSConfig tls_config = 15;
    84  
    85    // Proxy URL, e.g. http://myproxy:3128
    86    optional string proxy_url = 16;
    87  
    88    // Interval between targets.
    89    optional int32 interval_between_targets_msec = 97 [default = 10];
    90  
    91    // Requests per probe.
    92    // Number of HTTP requests per probe. Requests are executed concurrently and
    93    // each HTTP re contributes to probe results. For example, if you run two
    94    // requests per probe, "total" counter will be incremented by 2.
    95    optional int32 requests_per_probe = 98 [default = 1];
    96  
    97    // How long to wait between two requests to the same target
    98    // NOTE: This field is now deprecated and will be removed after the v0.10.3
    99    // releases.
   100    optional int32 requests_interval_msec = 99 [default = 25];
   101  }