5.25.0 — 2026-11-01¶
5.24.0 → | 5.26.0 → | ↑ 5.x series
Added¶
Adapters - Kafka¶
- SASL and SSL Settings - Each setting applies on its own:
security.protocolis always set, SASL settings apply forSASL_*protocols and SSL settings forSSLandSASL_SSL. mTLS-only,SASL_PLAINTEXT, GSSAPI, OAUTHBEARER and system CA stores work now.KafkaConfigrequires a SASL mechanism for SASL protocols, and a username and password only forPLAINandSCRAM
- Client Options -
SOCKET_TIMEOUT_MS,RECONNECT_BACKOFF_MAX_MS,RETRY_BACKOFF_MS,MESSAGE_TIMEOUT_MS,GROUP_INSTANCE_IDandENABLE_AUTO_OFFSET_STOREare optional settings; unset keeps the librdkafka default.
Adapters - Redis¶
- TLS and ACL Login -
USERNAME,SSL,SSL_CA_CERTS,SSL_CERTFILE,SSL_KEYFILEandSSL_CHECK_HOSTNAMEwork for standalone, cluster and sentinel clients, sync and async. - Retry and Connection Options -
RETRY_ATTEMPTS,RETRY_BACKOFF_BASE,RETRY_BACKOFF_CAP,RETRY_ON_TIMEOUT,SOCKET_KEEPALIVE,CLIENT_NAMEandSENTINEL_USERNAME; unset keeps the redis-py defaults.
Adapters - ScyllaDB¶
- TLS -
TLS_ENABLED,TLS_CA_FILE,TLS_CERT_FILE,TLS_KEY_FILE,TLS_VERIFY_MODEandTLS_CHECK_HOSTNAMEbuild thessl_contextof the sync and async clusters. - Resilience Options - Idle heartbeat interval and timeout, control connection timeout, reconnection policy, serial consistency level and speculative execution apply to the cluster and the default execution profile.
Adapters - Email¶
- TLS Modes -
TLS_MODEisnone,starttls(required: a failed upgrade raises instead of sending in clear text) orimplicit(port 465), next toTLS_CA_FILE,TLS_VERIFY,LOCAL_HOSTNAME,SOURCE_ADDRESSandSOURCE_PORT.- A half-set username and password pair is rejected outside the
automode
- A half-set username and password pair is rejected outside the
Adapters - PostgreSQL and MySQL¶
- TLS - PostgreSQL
SSL_MODE,SSL_ROOT_CERT,SSL_CERTandSSL_KEY; MySQLSSL_MODE,SSL_CA,SSL_CERTandSSL_KEY. Sync and async. - Timeouts and Options - MySQL
CONNECT_TIMEOUT,READ_TIMEOUT,WRITE_TIMEOUT(pymysql only),STATEMENT_TIMEOUT_MSandLOCK_WAIT_TIMEOUT_SECONDS; PostgreSQLSTATEMENT_TIMEOUT_MS,LOCK_TIMEOUT_MS,APPLICATION_NAME,PREPARE_THRESHOLDandDISABLE_PREPARED_STATEMENTSfor pgbouncer in transaction mode.
Adapters - SQLite¶
- Busy Timeout -
TIMEOUTsets the busy timeout andCHECK_SAME_THREADthe sync driver option.
Adapters - Elasticsearch¶
- Client Options -
BEARER_AUTH,CLOUD_ID,SSL_VERSION,SSL_CONTEXT,OPAQUE_IDandHEADERSare passed to the sync and async clients when set. Bearer auth is rejected together with an API key or basic auth, andCLOUD_IDreplacesHOSTS.
Adapters - Keycloak¶
- Connection Settings -
VERIFY_SSLaccepts a CA bundle path andTIMEOUTa float. NewCLIENT_CERT_FILEandCLIENT_KEY_FILE(mTLS),MAX_RETRIES,POOL_MAXSIZE,PROXIESandCUSTOM_HEADERSreach every python-keycloak client.- python-keycloak has no connect and read timeout split, and its async admin and UMA clients take no proxies
Adapters - MinIO¶
- Client Options -
CLIENT_CERT,CLIENT_KEY,PROXIES,PROXIES_CONFIG,TCP_KEEPALIVE,USER_AGENT_EXTRAandPROFILE_NAMEreach the botocore client; a profile withrole_arncovers STS assume-role.
Configs - Uvicorn¶
- UVICORN Section - The Uvicorn server settings live in the new
UVICORNsection, withSSL_KEYFILE,SSL_CERTFILEandSSL_CA_CERTSfor TLS (the key and certificate must come together).AppUtils.uvicorn_config()builds theuvicorn.runarguments from it and drops unset optional settings.
Configs - gRPC¶
- TLS and mTLS -
TLS_*andSTUB_TLS_*settings, withAppUtils.add_grpc_portfor secure server ports andAppUtils.create_grpc_channelfor secure channels. Off by default. - Compression and Shutdown -
SERVER_COMPRESSION,STUB_COMPRESSIONandSHUTDOWN_GRACE_SECONDS, withAppUtils.stop_grpc_app. Server option values may be strings as well as integers.
Changed¶
Adapters - Kafka¶
- List Topics Timeout - Behavior:
list_topics()without a timeout waitsLIST_TOPICS_TIMEOUT_MS(5 seconds) instead of 1 second.
Adapters - Elasticsearch¶
- Sniff Delay - Behavior: with
SNIFF_BEFORE_REQUESTSon, the delay between sniffs isMIN_DELAY_BETWEEN_SNIFFING(60 seconds by default) instead of the library's 10 seconds.
Adapters - Email¶
- TLS Mode Default - The default
TLS_MODEautokeeps the old opportunistic STARTTLS and is deprecated; setstarttls,implicitornoneexplicitly.
Configs - FastAPI¶
- Uvicorn Settings Moved - Deprecated: the uvicorn fields of
FASTAPI(ACCESS_LOG,BACKLOG,DATE_HEADER,FORWARDED_ALLOW_IPS,LIMIT_CONCURRENCY,LIMIT_MAX_REQUESTS,PROXY_HEADERS,RELOAD,SERVER_HEADER,TIMEOUT_GRACEFUL_SHUTDOWN,TIMEOUT_KEEP_ALIVE,WORKERS_COUNTand the fourWS_*) move toUVICORN. They still apply when the matchingUVICORNfield is unset.- Building
FastAPIConfigwith one, or reading one, emits aDeprecationWarning; the JSON schema marks it deprecated - Removed in 6.0.0; see the deprecations page
- Building
Configs - ScyllaDB¶
- Pool Fields Deprecated - Deprecated:
MAX_CONNECTIONS_PER_HOST,MIN_CONNECTIONS_PER_HOST,CORE_CONNECTIONS_PER_HOSTandMAX_REQUESTS_PER_CONNECTIONare marked with pydanticdeprecated, so reading one warns. They never had an effect and are removed in 6.0.0.
Fixed¶
Adapters - Kafka¶
- Dropped Settings -
CLIENT_ID,CONNECTIONS_MAX_IDLE_MSandLIST_TOPICS_TIMEOUT_MSare applied; they were never read. - Silent Plaintext - A config with a SASL or SSL protocol and no username, password and CA together no longer falls back to plaintext without notice.
Adapters - Elasticsearch¶
- Dropped Settings -
NODE_SELECTOR_CLASS,DEAD_NODE_BACKOFF_FACTOR,MIN_DELAY_BETWEEN_SNIFFINGandIGNORE_STATUSare applied to the sync and async clients; they were never passed on.
Adapters - Email¶
- STARTTLS Downgrade - With
TLS_MODEset tostarttls, a failed upgrade raises instead of sending the login in clear text.
Tests¶
Tests - Configuration¶
- New Scenarios - Redis ACL login on a container, Postgres and MySQL TLS and timeouts on real containers, SQLite busy timeout, gRPC TLS and mTLS against real servers, ScyllaDB TLS contexts built from generated certificates, Kafka option outlines, Elasticsearch option wiring, and the deprecated field warnings.
- Redis TLS is tested at the client-settings level because there is no TLS server container, and Mailpit has no SMTPS listener, so email implicit TLS runs against a local TLS stub