github.com/muhammadn/cortex@v1.9.1-0.20220510110439-46bb7000d03d/docs/operations/requests-mirroring-envoy.yaml (about)

     1  admin:
     2    # No access logs.
     3    access_log_path: /dev/null
     4    address:
     5      socket_address: { address: 0.0.0.0, port_value: 9901 }
     6  
     7  static_resources:
     8    listeners:
     9      - name: cortex_listener
    10        address:
    11          socket_address: { address: 0.0.0.0, port_value: 9900 }
    12        filter_chains:
    13          - filters:
    14              - name: envoy.http_connection_manager
    15                config:
    16                  stat_prefix: cortex_ingress
    17                  route_config:
    18                    name: all_routes
    19                    virtual_hosts:
    20                      - name: all_hosts
    21                        domains: ["*"]
    22                        routes:
    23                          - match: { prefix: "/" }
    24                            route:
    25                              cluster: cortex_primary
    26  
    27                              # Specifies the upstream timeout. This spans between the point at which the entire downstream
    28                              # request has been processed and when the upstream response has been completely processed.
    29                              timeout: 15s
    30  
    31                              # Specifies the cluster that requests will be mirrored to. The performances and availability of
    32                              # the secondary cluster have no impact on the requests to the primary one. The response to the
    33                              # client will always be the one from the primary one. The requests from Envoy to the secondary
    34                              # cluster are "fire and forget".
    35                              request_mirror_policies:
    36                                - cluster: cortex_secondary
    37                  http_filters:
    38                    - name: envoy.router
    39    clusters:
    40      - name: cortex_primary
    41        type: STRICT_DNS
    42        connect_timeout: 1s
    43        hosts: [{ socket_address: { address: cortex-primary, port_value: 80 }}]
    44        dns_refresh_rate: 5s
    45      - name: cortex_secondary
    46        type: STRICT_DNS
    47        connect_timeout: 1s
    48        hosts: [{ socket_address: { address: cortex-secondary, port_value: 80 }}]
    49        dns_refresh_rate: 5s