Uploaded image for project: 'Red Hat 3scale API Management'
  1. Red Hat 3scale API Management
  2. THREESCALE-8149

Enable to configure the Upstream Connection timeouts globally

XMLWordPrintable

    • Icon: Feature Request Feature Request
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 2.11.1 GA
    • Gateway
    • False
    • False
    • Not Started
    • Not Started
    • Not Started
    • Not Started
    • Not Started
    • Not Started
    • RHOAM Sprint 62

      Currently it is only possible to configure the Upstream Connection Policy by Product.

      The request is to be able to configure the timeouts handled by the policy globally for all services, for example via environment variables.

       

      Update 09.08.2024

      Fixed in THREESCALE-9320.

      How to test

      • Create a lua file call upstream_connection_custom_env.lua with the following content.
      local cjson = require('cjson')
      local PolicyChain = require('apicast.policy_chain')
      local policy_chain = context.policy_chain
      
      local upstream_connection_policy_config = cjson.decode([[ { "send_timeout": 120, "connect_timeout": 120, "read_timeout": 120 } ]])
      policy_chain:insert( PolicyChain.load_policy('upstream_connection', 'builtin', upstream_connection_policy_config), 2) 
      
      return { policy_chain = policy_chain, port = { metrics = 9421 }
      • Create a secret with the custom environment content:
      oc create secret generic logging-custom-env --from-file=./upstream_connection_custom_env.lua
      • For self-managed APIcast, configure and deploy the APIcast CR with the APIcast custom environment:
      apiVersion: apps.3scale.net/v1alpha1
      kind: APIcast 
      metadata:
        name: apicast-staging 
      spec: 
        customEnvironments: 
          - secretRef:
            name: upstream_connection_custom_env
      • For managed APIcast, configure 3scale CR as follow:
      spec:
        apicast:
          productionSpec:
            customEnvironments:
              - secretRef:
                name: upstream_connection_custom_env

              Unassigned Unassigned
              rhn-support-sillumin Samuele Illuminati (Inactive)
              An Tran An Tran
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated: