Cld 9544 provisioner fix mysql db connection string#1139
Merged
Conversation
rahb3rt
approved these changes
Nov 7, 2025
nickmisasi
approved these changes
Nov 7, 2025
fmartingr
approved these changes
Nov 7, 2025
Contributor
fmartingr
left a comment
There was a problem hiding this comment.
Same as the other one, LGTM but I'm not sure why we are fixing MySQL related things. Am I missing context here?
Contributor
Author
We still have a few customers using it, and our QA team is using MySQL to test old versions. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This pull request enhances the handling of MySQL database connection strings by adding support for a new "datasource URL" format (without the
mysql://prefix) in the database secret generation and Kubernetes secret creation processes. This change ensures that both the original connection string and the datasource URL are available for use in different contexts, improving compatibility and flexibility.MySQL connection string improvements:
MattermostMySQLConnStringsfunction to return an additional datasource URL (connection string without themysql://prefix), alongside the existing connection string and read replica string.RDSDatabase.GenerateDatabaseSecretandRDSMultitenantDatabase.GenerateDatabaseSecretto capture and store the new datasource URL in the generated secret.Secret structure and Kubernetes integration:
DataSourceURLfield to theInstallationDBSecretstruct to store the datasource URL.ToK8sSecretmethod to include the datasource URL asMM_SQLSETTINGS_DATASOURCEin the generated Kubernetes secret if it is present.secret_test.goto verify correct handling of the datasource URL in secrets, including cases where it is present and absent.Secret generation updates:
DataSourceURLfield is set when generating secrets for both single-tenant and multitenant RDS databases.Ticket Link
https://mattermost.atlassian.net/browse/CLD-9544
Release Note