-
Notifications
You must be signed in to change notification settings - Fork 14.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix metadata DB & port in Keda connection when usePgbouncer is false #34741
Fix metadata DB & port in Keda connection when usePgbouncer is false #34741
Conversation
@brokenjacobs this should fix the issue. Usually we don't create patch releases for the chart, but maybe we can wait a week and release a light patch release if other bugs are reported (to check with @jedcunningham) |
Yep, open to it. We've never really had the need before. |
Please see #34740 the database name is also incorrect. It uses the db name defined in the pgbouncer.ini, not the upstream database name. |
Thanks for your work on this! |
Indeed, I fixed it and I checked all the other values, all looks good! |
@@ -48,7 +49,7 @@ data: | |||
{{- end }} | |||
{{- if and .Values.workers.keda.enabled .Values.pgbouncer.enabled (not .Values.workers.keda.usePgbouncer) }} | |||
{{- with .Values.data.metadataConnection }} | |||
kedaConnection: {{ urlJoin (dict "scheme" .protocol "userinfo" (printf "%s:%s" (.user | urlquery) (.pass | urlquery) ) "host" (printf "%s:%s" $metadataHost $metadataPort) "path" (printf "/%s" $database) "query" $query) | b64enc | quote }} | |||
kedaConnection: {{ urlJoin (dict "scheme" .protocol "userinfo" (printf "%s:%s" (.user | urlquery) (.pass | urlquery) ) "host" (printf "%s:%s" $metadataHost $metadataPort) "path" (printf "/%s" $meadataDatabase) "query" $query) | b64enc | quote }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo nit meadataDatabase -> metadataDatabase
@@ -27,7 +27,8 @@ | |||
{{- $host := ternary $pgbouncerHost $metadataHost .Values.pgbouncer.enabled }} | |||
{{- $metadataPort := .Values.data.metadataConnection.port | toString }} | |||
{{- $port := ((ternary .Values.ports.pgbouncer $metadataPort .Values.pgbouncer.enabled) | toString) }} | |||
{{- $database := (ternary (printf "%s-%s" .Release.Name "metadata") .Values.data.metadataConnection.db .Values.pgbouncer.enabled) }} | |||
{{- $meadataDatabase := .Values.data.metadataConnection.db }} | |||
{{- $database := (ternary (printf "%s-%s" .Release.Name "metadata") $meadataDatabase .Values.pgbouncer.enabled) }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typo nit. $meadataDatabase -> metadataDatabase
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
closes: #34740
When
usePgbouncer
and KEDA is activated, KEDA connection should use the metadata port instead of pgbouncer port.