package
2.0.3+incompatible
Repository: https://github.com/3scale/istio-integration.git
Documentation: pkg.go.dev

# README

gRPC Server

An out of process gRPC Adapter which integrates 3scale with Istio

Configuring the adapter

The runtime behaviour of the adapter can be modified by editing the deployment and setting or configuring the following environment variables:

VariableDescriptionDefault
LISTEN_ADDRSets the listen address for the gRPC server0
LOG_LEVELSets the minimum log output level. Accepted values are one of debug,info,warn,error,noneinfo
LOG_JSONControls whether the log is formatted as JSONtrue
LOG_GRPCControls whether the log includes gRPC infofalse
REPORT_METRICSControls whether 3scale system and backend metrics are collected and reported to Prometheustrue
METRICS_PORTSets the port which 3scale /metrics endpoint can be scrapped from8080
CACHE_TTL_SECONDSTime period, in seconds, to wait before purging expired items from the cache300
CACHE_REFRESH_SECONDSTime period in seconds, before a background process attempts to refresh cached entries180
CACHE_ENTRIES_MAXMax number of items that can be stored in the cache at any time. Set to 0 to disable caching1000
CACHE_REFRESH_RETRIESSets the number of times unreachable hosts will be retried during a cache update loop1
ALLOW_INSECURE_CONNAllow to skip certificate verification when calling 3scale API's. Enabling is not recommendedfalse
ROOT_CAPath to root CA file using PEM formatN/A
CLIENT_CERTPath to client certificate (public key) using PEM format (requires CLIENT_KEY)N/A
CLIENT_KEYPath to client key (private key) using PEM format (requires CLIENT_CERT)N/A
CLIENT_TIMEOUT_SECONDSSets the number of seconds to wait before terminating requests to 3scale System and Backend10
GRPC_CONN_MAX_SECONDSSets the maximum amount of seconds (+/-10% jitter) a connection may exist before it will be closed60
USE_CACHED_BACKENDIf true, attempt to create an in-memory apisonator cache for authorization requestsfalse
BACKEND_CACHE_FLUSH_INTERVAL_SECONDSIf the backend cache is enabled, this sets the interval in seconds for flushing the cache against 3scale15
BACKEND_CACHE_POLICY_FAIL_CLOSEDWhenever the backend cache cannot retrieve authorization data, whether to deny (closed) or allow (open) requeststrue

Configuration Caching Behaviour

By default, responses from 3scale System API's will be cached. Entries will be purged from the cache when they become older than the CACHE_TTL_SECONDS value. Again by default however, automatic refreshing of cached entries will be attempted some seconds before they expire, based on the CACHE_REFRESH_SECONDS value. Automatic refreshing can be disabled by setting this value higher than the CACHE_TTL_SECONDS value.

Caching can be disabled entirely by setting CACHE_ENTRIES_MAX to a non-positive value.

Through the refreshing process, cached values whose hosts become unreachable will be retried before eventually being purged when past their expiry.