Skip to content

Commit

Permalink
Log the database name secret
Browse files Browse the repository at this point in the history
  • Loading branch information
dragomirp committed Jan 9, 2025
1 parent c31152d commit 754f121
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/relations/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,8 @@ def set_up_relation(self, relation: Relation) -> bool:
if not database:
database = self.charm.get_secret(APP_SCOPE, f"{user}-database")

logger.error(f"!!!!!!!!!!!!!!!!!!!!!!!!11{database}")

# Store the user, password and database name in the secret store to be accessible by
# non-leader units when the cluster topology changes.
self.charm.set_secret(APP_SCOPE, user, password)
Expand Down
3 changes: 3 additions & 0 deletions tests/integration/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,9 @@ async def deploy_and_relate_bundle_with_postgresql(

# Remove PostgreSQL and relations with it from the bundle.yaml file.
config = data["applications"]["postgresql"]["options"]
# Limit the amount of max connections
if config["experimental_max_connections"] > 100:
config["experimental_max_connections"] = 150
for key, val in config.items():
config[key] = str(val)
logger.info(f"Bundle {bundle_name} needs configuration {config}")
Expand Down

0 comments on commit 754f121

Please sign in to comment.