Merge lp:~gnuoy/charms/trusty/cinder/bug1403132 into lp:~openstack-charmers-archive/charms/trusty/cinder/next

Proposed by Liam Young
Status: Merged
Merged at revision: 70
Proposed branch: lp:~gnuoy/charms/trusty/cinder/bug1403132
Merge into: lp:~openstack-charmers-archive/charms/trusty/cinder/next
Diff against target: 101 lines (+15/-6)
3 files modified
config.yaml (+1/-1)
hooks/cinder_hooks.py (+7/-3)
unit_tests/test_cluster_hooks.py (+7/-2)
To merge this branch: bzr merge lp:~gnuoy/charms/trusty/cinder/bug1403132
Reviewer Review Type Date Requested Status
James Page Approve
Review via email: mp+247153@code.launchpad.net
To post a comment you must log in.
Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_lint_check #942 cinder-next for gnuoy mp247153
    LINT OK: passed

Build: http://10.245.162.77:8080/job/charm_lint_check/942/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_unit_test #971 cinder-next for gnuoy mp247153
    UNIT OK: passed

Build: http://10.245.162.77:8080/job/charm_unit_test/971/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_amulet_test #1164 cinder-next for gnuoy mp247153
    AMULET FAIL: amulet-test failed

AMULET Results (max last 2 lines):
  ERROR subprocess encountered error code 1
  make: *** [test] Error 1

Full amulet test output: http://paste.ubuntu.com/9806533/
Build: http://10.245.162.77:8080/job/charm_amulet_test/1164/

Revision history for this message
Ryan Beisner (1chb1n) wrote :

FYI, all deploy tests are happy. [P-I, T-I, T-J, U-J] x [Stable & Next] charms.

FYI Amulet fails on cinder/next proper, so that is not caused by this MP. Investigating that.

71. By Liam Young

Propogate corosync config option set in the charm to the hacluster subordinate

72. By Liam Young

Fix unit tests

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_lint_check #1035 cinder-next for gnuoy mp247153
    LINT OK: passed

Build: http://10.245.162.77:8080/job/charm_lint_check/1035/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_unit_test #1027 cinder-next for gnuoy mp247153
    UNIT OK: passed

Build: http://10.245.162.77:8080/job/charm_unit_test/1027/

Revision history for this message
uosci-testing-bot (uosci-testing-bot) wrote :

charm_amulet_test #1215 cinder-next for gnuoy mp247153
    AMULET OK: passed

Build: http://10.245.162.77:8080/job/charm_amulet_test/1215/

Revision history for this message
Liam Young (gnuoy) wrote :

Tested upgrade with mojo spec dev/multicast_port_change lp:~ost-maintainers/openstack-mojo-specs/mojo-openstack-specs

Revision history for this message
James Page (james-page) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'config.yaml'
2--- config.yaml 2015-01-13 14:36:44 +0000
3+++ config.yaml 2015-01-22 16:51:22 +0000
4@@ -138,7 +138,7 @@
5 with the other members of the HA Cluster.
6 ha-mcastport:
7 type: int
8- default: 5401
9+ default: 5454
10 description: |
11 Default multicast port number that will be used to communicate between
12 HA Cluster nodes.
13
14=== modified file 'hooks/cinder_hooks.py'
15--- hooks/cinder_hooks.py 2015-01-13 14:36:44 +0000
16+++ hooks/cinder_hooks.py 2015-01-22 16:51:22 +0000
17@@ -130,6 +130,8 @@
18
19 for rid in relation_ids('cluster'):
20 cluster_joined(relation_id=rid)
21+ for r_id in relation_ids('ha'):
22+ ha_joined(relation_id=r_id)
23
24
25 @hooks.hook('shared-db-relation-joined')
26@@ -323,7 +325,7 @@
27
28
29 @hooks.hook('ha-relation-joined')
30-def ha_joined():
31+def ha_joined(relation_id=None):
32 cluster_config = get_hacluster_config()
33
34 resources = {
35@@ -361,7 +363,8 @@
36 vip_group.append(vip_key)
37
38 if len(vip_group) >= 1:
39- relation_set(groups={'grp_cinder_vips': ' '.join(vip_group)})
40+ relation_set(relation_id=relation_id,
41+ groups={'grp_cinder_vips': ' '.join(vip_group)})
42
43 init_services = {
44 'res_cinder_haproxy': 'haproxy'
45@@ -369,7 +372,8 @@
46 clones = {
47 'cl_cinder_haproxy': 'res_cinder_haproxy'
48 }
49- relation_set(init_services=init_services,
50+ relation_set(relation_id=relation_id,
51+ init_services=init_services,
52 corosync_bindiface=cluster_config['ha-bindiface'],
53 corosync_mcastport=cluster_config['ha-mcastport'],
54 resources=resources,
55
56=== modified file 'unit_tests/test_cluster_hooks.py'
57--- unit_tests/test_cluster_hooks.py 2015-01-13 14:36:44 +0000
58+++ unit_tests/test_cluster_hooks.py 2015-01-22 16:51:22 +0000
59@@ -136,6 +136,7 @@
60 'res_cinder_haproxy': 'op monitor interval="5s"'
61 },
62 'corosync_bindiface': 'eth100',
63+ 'relation_id': None,
64 'clones': {'cl_cinder_haproxy': 'res_cinder_haproxy'},
65 'resources': {
66 'res_cinder_eth101_vip': 'ocf:heartbeat:IPaddr2',
67@@ -143,7 +144,8 @@
68 }
69 }
70 self.relation_set.assert_has_calls([
71- call(groups={'grp_cinder_vips': 'res_cinder_eth101_vip'}),
72+ call(relation_id=None,
73+ groups={'grp_cinder_vips': 'res_cinder_eth101_vip'}),
74 call(**ex_args)
75 ])
76
77@@ -163,6 +165,7 @@
78 self.get_netmask_for_address.return_value = 'ffff.ffff.ffff.ffff'
79 hooks.hooks.execute(['hooks/ha-relation-joined'])
80 ex_args = {
81+ 'relation_id': None,
82 'corosync_mcastport': '37373',
83 'init_services': {'res_cinder_haproxy': 'haproxy'},
84 'resource_params': {
85@@ -200,6 +203,7 @@
86 self.get_netmask_for_address.return_value = None
87 hooks.hooks.execute(['hooks/ha-relation-joined'])
88 ex_args = {
89+ 'relation_id': None,
90 'corosync_mcastport': '37373',
91 'init_services': {'res_cinder_haproxy': 'haproxy'},
92 'resource_params': {
93@@ -216,7 +220,8 @@
94 }
95 }
96 self.relation_set.assert_has_calls([
97- call(groups={'grp_cinder_vips': 'res_cinder_eth120_vip'}),
98+ call(relation_id=None,
99+ groups={'grp_cinder_vips': 'res_cinder_eth120_vip'}),
100 call(**ex_args)
101 ])
102

Subscribers

People subscribed via source and target branches