-
Notifications
You must be signed in to change notification settings - Fork 29
[DPE-8473] Handle invalid database name (databases)
#1108
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
Merged
Merged
Conversation
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
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## 16/edge #1108 +/- ##
===========================================
+ Coverage 67.23% 67.29% +0.05%
===========================================
Files 19 19
Lines 3956 3951 -5
Branches 564 564
===========================================
- Hits 2660 2659 -1
+ Misses 1123 1119 -4
Partials 173 173 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…lid database name and to handle storage ownership and permissions Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
9bc9be2 to
13c94d6
Compare
…se-name Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
…se-name Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
…se-name Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
2 tasks
databases)
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
…se-name Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
dragomirp
approved these changes
Oct 7, 2025
2 tasks
taurus-forever
approved these changes
Oct 9, 2025
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.
Issue
With the new predefined roles implemented for PG 16, if a client app requests a database called databases while the PG charm tries to set up the roles for it, a failure will happen because one of the roles will conflict with the already existing charmed_databases_owner role (responsible for owning all the databases).
Solution
This PR is a follow-up from canonical/postgresql-single-kernel-library#18.
The data directory permissions were fixed, as it was done on canonical/postgresql-operator#1156. Some more fixes across this charm codebase might need to be done to make everything consistent.
Another thing that was done in this PR was to move the Pebble container that is retrieved multiple times in
src/charm.pyto a cached property. There are still some other places in other Python files that retrieve the Pebble container and need to be updated. This new cached property will also be useful when we start passing the container to the single kernel library objects.Checklist