Merge lp:~seyeongkim/charms/trusty/swift-proxy/lp1334648 into lp:~openstack-charmers-archive/charms/trusty/swift-proxy/next
- Trusty Tahr (14.04)
- lp1334648
- Merge into next
Status: | Superseded |
---|---|
Proposed branch: | lp:~seyeongkim/charms/trusty/swift-proxy/lp1334648 |
Merge into: | lp:~openstack-charmers-archive/charms/trusty/swift-proxy/next |
Diff against target: |
131 lines (+47/-7) 4 files modified
config.yaml (+12/-0) hooks/swift_context.py (+12/-0) templates/icehouse/proxy-server.conf (+10/-2) tests/basic_deployment.py (+13/-5) |
To merge this branch: | bzr merge lp:~seyeongkim/charms/trusty/swift-proxy/lp1334648 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ryan Beisner (community) | Needs Fixing | ||
OpenStack Charmers | Pending | ||
Edward Hope-Morley | Pending | ||
James Page | Pending | ||
Review via email: mp+255343@code.launchpad.net |
This proposal supersedes a proposal from 2015-02-10.
Commit message
Description of the change
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1250 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1351 swift-proxy-next for xtrusia mp247835
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://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1352 swift-proxy-next for xtrusia mp247835
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://
Build: http://
Ryan Beisner (1chb1n) wrote : Posted in a previous version of this proposal | # |
FYI I triggered another run of the amulet test to confirm failure.
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1408 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1455 swift-proxy-next for xtrusia mp247835
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1573 swift-proxy-next for xtrusia mp247835
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://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1457 swift-proxy-next for xtrusia mp247835
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1410 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1575 swift-proxy-next for xtrusia mp247835
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://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1458 swift-proxy-next for xtrusia mp247835
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1411 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1576 swift-proxy-next for xtrusia mp247835
AMULET OK: passed
Build: http://
Edward Hope-Morley (hopem) wrote : Posted in a previous version of this proposal | # |
Seyeong thanks a lot for adding this in it is very much needed indeed. I would like to deploy it before giving a +1 and will endeavour to do so asap. Thanks.
Edward Hope-Morley (hopem) wrote : Posted in a previous version of this proposal | # |
Ok finally tested this out and it seems to work well. There a few things that should be cleaned up though (see inline).
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1825 swift-proxy-next for xtrusia mp247835
LINT FAIL: lint-test failed
LINT FAIL: charm-proof failed
LINT Results (max last 2 lines):
W: config.yaml: option keystone-
make: *** [lint] Error 100
Full lint test output: http://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1653 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1844 swift-proxy-next for xtrusia mp247835
AMULET OK: passed
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1660 swift-proxy-next for xtrusia mp247835
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1832 swift-proxy-next for xtrusia mp247835
LINT FAIL: lint-test failed
LINT FAIL: charm-proof failed
LINT Results (max last 2 lines):
W: config.yaml: option keystone-
make: *** [lint] Error 100
Full lint test output: http://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1851 swift-proxy-next for xtrusia mp247835
AMULET OK: passed
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #1835 swift-proxy-next for xtrusia mp249176
LINT FAIL: lint-test failed
LINT FAIL: charm-proof failed
LINT Results (max last 2 lines):
W: config.yaml: option keystone-
make: *** [lint] Error 100
Full lint test output: http://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #1663 swift-proxy-next for xtrusia mp249176
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #1854 swift-proxy-next for xtrusia mp249176
AMULET OK: passed
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_lint_check #2279 swift-proxy-next for xtrusia mp249176
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_unit_test #2068 swift-proxy-next for xtrusia mp249176
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : Posted in a previous version of this proposal | # |
charm_amulet_test #2184 swift-proxy-next for xtrusia mp249176
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://
Build: http://
James Page (james-page) wrote : Posted in a previous version of this proposal | # |
A few queries - see inline comments.
Seyeong Kim (seyeongkim) wrote : Posted in a previous version of this proposal | # |
please see inline reply
James Page (james-page) : Posted in a previous version of this proposal | # |
James Page (james-page) wrote : Posted in a previous version of this proposal | # |
This still needs my feedback on my last review incorporating - we should not expose all swift configuration options via charm config:
"I'm keen we expose a charm configuration option that makes sense to the charm user, not all swift logging options. So please can we use the following config options: debug: [true|false] (this is consistent with other charms) log-headers: [true|false] (specific to swift) These should be translated into underlying swift configuration appropriately."
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_lint_check #3100 swift-proxy-next for xtrusia mp255343
LINT FAIL: lint-test failed
LINT FAIL: charm-proof failed
LINT Results (max last 2 lines):
make: *** [lint] Error 200
ERROR:root:Make target returned non-zero.
Full lint test output: http://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_unit_test #2888 swift-proxy-next for xtrusia mp255343
UNIT OK: passed
- 92. By Seyeong Kim
-
fix debug type
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_amulet_test #2922 swift-proxy-next for xtrusia mp255343
AMULET FAIL: amulet-test failed
AMULET Results (max last 2 lines):
make: *** [test] Error 1
ERROR:root:Make target returned non-zero.
Full amulet test output: http://
Build: http://
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_lint_check #3101 swift-proxy-next for xtrusia mp255343
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_unit_test #2889 swift-proxy-next for xtrusia mp255343
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_amulet_test #2923 swift-proxy-next for xtrusia mp255343
AMULET FAIL: amulet-test failed
AMULET Results (max last 2 lines):
make: *** [test] Error 1
ERROR:root:Make target returned non-zero.
Full amulet test output: http://
Build: http://
Ryan Beisner (1chb1n) wrote : | # |
Baseline amulet tests for swift-proxy/next are passing. Please see in-line comment regarding missing comma and duplicate key:pair definition. Thank you.
- 93. By Seyeong Kim
-
fix mistake on basic_deployment.py
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_lint_check #3102 swift-proxy-next for xtrusia mp255343
LINT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_unit_test #2890 swift-proxy-next for xtrusia mp255343
UNIT OK: passed
uosci-testing-bot (uosci-testing-bot) wrote : | # |
charm_amulet_test #2924 swift-proxy-next for xtrusia mp255343
AMULET FAIL: amulet-test failed
AMULET Results (max last 2 lines):
make: *** [test] Error 1
ERROR:root:Make target returned non-zero.
Full amulet test output: http://
Build: http://
- 94. By Seyeong Kim
-
amulet test
- 95. By Seyeong Kim
-
fix config.yaml
- 96. By Seyeong Kim
-
test
- 97. By Seyeong Kim
-
fix some amulet test
- 98. By Seyeong Kim
-
fix some amulet test
- 99. By Seyeong Kim
-
default things to template, more option on if branch
- 100. By Seyeong Kim
-
remove test timeout
Unmerged revisions
- 100. By Seyeong Kim
-
remove test timeout
- 99. By Seyeong Kim
-
default things to template, more option on if branch
- 98. By Seyeong Kim
-
fix some amulet test
- 97. By Seyeong Kim
-
fix some amulet test
- 96. By Seyeong Kim
-
test
- 95. By Seyeong Kim
-
fix config.yaml
- 94. By Seyeong Kim
-
amulet test
- 93. By Seyeong Kim
-
fix mistake on basic_deployment.py
- 92. By Seyeong Kim
-
fix debug type
- 91. By Seyeong Kim
-
fix conflicts
Preview Diff
1 | === modified file 'config.yaml' |
2 | --- config.yaml 2015-03-05 02:03:29 +0000 |
3 | +++ config.yaml 2015-04-07 11:48:02 +0000 |
4 | @@ -116,6 +116,18 @@ |
5 | Timeouts from these requests can be recovered from so setting this to |
6 | something lower than node-timeout would provide quicker error recovery |
7 | while allowing for a longer timeout for non-recoverable requests (PUTs). |
8 | + # Logging configuration |
9 | + debug: |
10 | + default: false |
11 | + type: boolean |
12 | + description: | |
13 | + Set log-name, log-facility, log-level, log-address |
14 | + log-headers: |
15 | + default: false |
16 | + type: boolean |
17 | + description: | |
18 | + Enables the ability to log request headers. |
19 | + The default is False. |
20 | # Manual Keystone configuration. |
21 | keystone-auth-host: |
22 | type: string |
23 | |
24 | === modified file 'hooks/swift_context.py' |
25 | --- hooks/swift_context.py 2015-03-31 08:39:46 +0000 |
26 | +++ hooks/swift_context.py 2015-04-07 11:48:02 +0000 |
27 | @@ -81,6 +81,11 @@ |
28 | def __call__(self): |
29 | bind_port = config('bind-port') |
30 | workers = config('workers') |
31 | + log_name = 'swift' |
32 | + log_facility = 'LOG_LOCAL0' |
33 | + log_level = 'INFO' |
34 | + log_address = '/dev/log' |
35 | + |
36 | if workers == 0: |
37 | import multiprocessing |
38 | workers = multiprocessing.cpu_count() |
39 | @@ -100,8 +105,15 @@ |
40 | 'delay_auth_decision': config('delay-auth-decision'), |
41 | 'node_timeout': config('node-timeout'), |
42 | 'recoverable_node_timeout': config('recoverable-node-timeout'), |
43 | + 'log_headers': config('log-headers'), |
44 | } |
45 | |
46 | + if config('debug'): |
47 | + ctxt['log_name'] = log_name |
48 | + ctxt['log_facility'] = log_facility |
49 | + ctxt['log_level'] = log_level |
50 | + ctxt['log_address'] = log_address |
51 | + |
52 | # Instead of duplicating code lets use charm-helpers to set signing_dir |
53 | # TODO(hopem): refactor this context handler to use charm-helpers |
54 | # code. |
55 | |
56 | === modified file 'templates/icehouse/proxy-server.conf' |
57 | --- templates/icehouse/proxy-server.conf 2015-02-20 10:20:45 +0000 |
58 | +++ templates/icehouse/proxy-server.conf 2015-04-07 11:48:02 +0000 |
59 | @@ -3,6 +3,11 @@ |
60 | workers = {{ workers }} |
61 | user = swift |
62 | bind_ip = {{ bind_host }} |
63 | +log_name = {{ log_name }} |
64 | +log_facility = {{ log_facility }} |
65 | +log_level = {{ log_level }} |
66 | +log_headers = {{ log_headers }} |
67 | +log_address = {{ log_address }} |
68 | {% if ssl %} |
69 | cert_file = {{ ssl_cert }} |
70 | key_file = {{ ssl_key }} |
71 | @@ -10,10 +15,10 @@ |
72 | |
73 | {% if auth_type == 'keystone' %} |
74 | [pipeline:main] |
75 | -pipeline = gatekeeper healthcheck cache swift3 s3token container_sync bulk tempurl slo dlo formpost authtoken keystoneauth staticweb container-quotas account-quotas proxy-server |
76 | +pipeline = gatekeeper healthcheck proxy-logging cache swift3 s3token container_sync bulk tempurl slo dlo formpost authtoken keystoneauth staticweb container-quotas account-quotas proxy-logging proxy-server |
77 | {% else %} |
78 | [pipeline:main] |
79 | -pipeline = gatekeeper healthcheck cache container_sync bulk tempurl slo dlo formpost tempauth staticweb container-quotas account-quotas proxy-server |
80 | +pipeline = gatekeeper healthcheck proxy-logging cache container_sync bulk tempurl slo dlo formpost tempauth staticweb container-quotas account-quotas proxy-logging proxy-server |
81 | {% endif %} |
82 | |
83 | [app:proxy-server] |
84 | @@ -40,6 +45,9 @@ |
85 | [filter:container-quotas] |
86 | use = egg:swift#container_quotas |
87 | |
88 | +[filter:proxy-logging] |
89 | +use = egg:swift#proxy_logging |
90 | + |
91 | [filter:staticweb] |
92 | use = egg:swift#staticweb |
93 | |
94 | |
95 | === modified file 'tests/basic_deployment.py' |
96 | --- tests/basic_deployment.py 2015-03-25 17:54:29 +0000 |
97 | +++ tests/basic_deployment.py 2015-04-07 11:48:02 +0000 |
98 | @@ -368,13 +368,20 @@ |
99 | expected = { |
100 | 'DEFAULT': { |
101 | 'bind_port': '8070', |
102 | - 'user': 'swift' |
103 | + 'workers': '0', |
104 | + 'user': 'swift', |
105 | + 'log_name': 'swift', |
106 | + 'log_facility': 'LOG_LOCAL0', |
107 | + 'log_level': 'INFO', |
108 | + 'log_headers': 'False', |
109 | + 'log_address': '/dev/log' |
110 | }, |
111 | 'pipeline:main': { |
112 | - 'pipeline': 'gatekeeper healthcheck cache swift3 s3token ' |
113 | - 'container_sync bulk tempurl slo dlo formpost ' |
114 | - 'authtoken keystoneauth staticweb ' |
115 | - 'container-quotas account-quotas proxy-server' |
116 | + 'pipeline': 'gatekeeper healthcheck proxy-logging cache swift3 ' |
117 | + 's3token container_sync bulk tempurl slo dlo ' |
118 | + 'formpost authtoken keystoneauth staticweb ' |
119 | + 'container-quotas account-quotas proxy-logging ' |
120 | + 'proxy-server' |
121 | }, |
122 | 'app:proxy-server': { |
123 | 'use': 'egg:swift#proxy', |
124 | @@ -395,6 +402,7 @@ |
125 | }, |
126 | 'filter:account-quotas': {'use': 'egg:swift#account_quotas'}, |
127 | 'filter:container-quotas': {'use': 'egg:swift#container_quotas'}, |
128 | + 'filter:proxy-logging': {'use': 'egg:swift#proxy_logging'}, |
129 | 'filter:staticweb': {'use': 'egg:swift#staticweb'}, |
130 | 'filter:bulk': {'use': 'egg:swift#bulk'}, |
131 | 'filter:slo': {'use': 'egg:swift#slo'}, |
charm_lint_check #1297 swift-proxy-next for xtrusia mp247835
LINT OK: passed
Build: http:// 10.245. 162.77: 8080/job/ charm_lint_ check/1297/