Merge lp://staging/~bjornt/charms/precise/storage/multiple-units into lp://staging/charms/storage

Proposed by Björn Tillenius
Status: Merged
Merged at revision: 43
Proposed branch: lp://staging/~bjornt/charms/precise/storage/multiple-units
Merge into: lp://staging/charms/storage
Diff against target: 35 lines (+21/-0)
1 file modified
hooks/storage-provider.d/block-storage-broker/block-storage-relation-changed (+21/-0)
To merge this branch: bzr merge lp://staging/~bjornt/charms/precise/storage/multiple-units
Reviewer Review Type Date Requested Status
Review Queue (community) automated testing Needs Fixing
Chris Glass (community) Approve
Review via email: mp+283321@code.staging.launchpad.net

Description of the change

Allow multiple storage units to work reliably.

Currently, the storage charm reads the block-device-path setting to get the path of the attached volume to mount. This is full of race conditions when you have multiple storage units, since that single setting is shared for all units. In practice, when you add a second storage unit, it will see the existing block-device-path setting for the first unit and try to mount it before any volume has been attached.

I've added a new relation setting, block-device-path-map, in lp:~bjornt/charms/trusty/block-storage-broker/multiple-units/. That works for multiple units. This branch will use it if exists, and if it doesn't, block-device-path is used as before. This ensures that using this branch with old versions of block-storage-broker won't break.

To post a comment you must log in.
Revision history for this message
Chris Glass (tribaal) wrote :

That looks great, thanks a lot.

One little nitpick inline, then I'll go ahead and merge.

review: Approve
45. By Björn Tillenius

Typos.

Revision history for this message
Review Queue (review-queue) wrote :

This item has failed automated testing! Results available here http://juju-ci.vapour.ws:8080/job/charm-bundle-test-lxc/2277/

review: Needs Fixing (automated testing)
Revision history for this message
Review Queue (review-queue) wrote :

This item has failed automated testing! Results available here http://juju-ci.vapour.ws:8080/job/charm-bundle-test-aws/2256/

review: Needs Fixing (automated testing)

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: