Merge lp://qastaging/~james-page/charms/precise/mysql/shared-db-multi into lp://qastaging/charms/mysql

Proposed by James Page
Status: Merged
Approved by: Clint Byrum
Approved revision: 91
Merged at revision: 91
Proposed branch: lp://qastaging/~james-page/charms/precise/mysql/shared-db-multi
Merge into: lp://qastaging/charms/mysql
Diff against target: 323 lines (+185/-105)
4 files modified
hooks/common.py (+55/-2)
hooks/shared-db-common (+0/-41)
hooks/shared-db-relations (+129/-61)
revision (+1/-1)
To merge this branch: bzr merge lp://qastaging/~james-page/charms/precise/mysql/shared-db-multi
Reviewer Review Type Date Requested Status
Adam Gandelman (community) Approve
Clint Byrum (community) Approve
Review via email: mp+137593@code.qastaging.launchpad.net

Description of the change

This MP adds a new feature to the shared-db relation; specifically it
allow multiple databases/users to be created across the interface in
a single transaction.

This was required to support deploying the Quantum API server as part
of the nova-cloud-controller charm; Quantum requires its own database
as it namespace conflicts with Nova.

The hook was originally written in bash; as this is a bit more complex
I took the opportunity to rewrite it in python to make handling the
multiple database creation a bit easier.

The existing charm interface remains intact.

Credit to Adam G for this approach; its the same as used in Keystone.

To post a comment you must log in.
Revision history for this message
Benjamin Kerensa (bkerensa) wrote :

Looks like a clean change to the hook to me... Good work

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Looks good. +1

review: Approve
Revision history for this message
Adam Gandelman (gandelman-a) wrote :

Thanks James. This works really well. I thought I was half-insane when I came up with this strategy for multi-endpoints in Keystone. Glad to see its working well elsewhere.

Merged with some whitespace cleanup.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to all changes: