Skip to content

Commit b41ab8c

Browse files
committed
LCORE-623: proper gss_encode config type in PostgreSQL connection configuration
1 parent fd4acfa commit b41ab8c

3 files changed

Lines changed: 10 additions & 32 deletions

File tree

docs/openapi.json

Lines changed: 8 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -16325,6 +16325,11 @@
1632516325
},
1632616326
"gss_encmode": {
1632716327
"type": "string",
16328+
"enum": [
16329+
"disable",
16330+
"prefer",
16331+
"require"
16332+
],
1632816333
"title": "GSS encmode",
1632916334
"description": "This option determines whether or with what priority a secure GSS TCP/IP connection will be negotiated with the server.",
1633016335
"default": "prefer"
@@ -19250,39 +19255,12 @@
1925019255
}
1925119256
],
1925219257
"title": "Filters",
19253-
"description": "Solr provider filter payload passed through as params['solr']. Supports structured metadata filters (eq, ne, in, nin comparison operators). Legacy filter-only objects (e.g. fq) are still accepted.",
19258+
"description": "Solr provider filter payload passed through as params['solr'].",
1925419259
"examples": [
19255-
{
19256-
"filters": {
19257-
"key": "product",
19258-
"type": "eq",
19259-
"value": "openshift_container_platform"
19260-
}
19261-
},
19262-
{
19263-
"filters": {
19264-
"filters": [
19265-
{
19266-
"key": "product",
19267-
"type": "eq",
19268-
"value": "openshift_container_platform"
19269-
},
19270-
{
19271-
"key": "version",
19272-
"type": "in",
19273-
"value": [
19274-
"4.14",
19275-
"4.15",
19276-
"4.16"
19277-
]
19278-
}
19279-
],
19280-
"type": "and"
19281-
}
19282-
},
1928319260
{
1928419261
"fq": [
19285-
"product:*openshift*"
19262+
"product:*openshift*",
19263+
"product_version:*4.16*"
1928619264
]
1928719265
}
1928819266
]

src/constants.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@
160160
# See: https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-SSLMODE
161161
POSTGRES_DEFAULT_SSL_MODE: Final[Literal["prefer"]] = "prefer"
162162
# See: https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNECT-GSSENCMODE
163-
POSTGRES_DEFAULT_GSS_ENCMODE: Final[str] = "prefer"
163+
POSTGRES_DEFAULT_GSS_ENCMODE: Final[Literal["prefer"]] = "prefer"
164164

165165
# cache constants
166166
CACHE_TYPE_MEMORY: Final[str] = "memory"

src/models/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ class PostgreSQLDatabaseConfiguration(ConfigurationBase):
236236
description="SSL mode",
237237
)
238238

239-
gss_encmode: str = Field(
239+
gss_encmode: Literal["disable", "prefer", "require"] = Field(
240240
constants.POSTGRES_DEFAULT_GSS_ENCMODE,
241241
title="GSS encmode",
242242
description="This option determines whether or with what priority a secure GSS "

0 commit comments

Comments
 (0)