Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(5029)

Issue 84630043: Support MachineInfo addresses.

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 1 month ago by frankban
Modified:
10 years ago
Reviewers:
mp+214317, rharding, bac
Visibility:
Public.

Description

Support MachineInfo addresses. juju-core 1.18 introduces a change in the mega-watcher: the MachineInfo includes the public/private addresses for each machine/container in the environment. This will be the preferred way to retrieve entity addresses in future versions of juju-core, which might also discard the public address field in the UnitInfo. This branch updates quickstart so that it can work in both scenarios: for backward compatibility, the address is retrieved trying to parse both the unit and the machine info, without assuming the corresponding fields to be always included. This required some testing and documentation efforts, resulting in a diff longer than usual: sorry about that. Tests: `make check`. QA: Use juju 1.16 (current stable). In the steps below the command to run is: `.venv/bin/python juju-quickstart -e {ENV_NAME}`. 1) Bootstrap a local environment with quickstart, ensure the quickstart process completes correctly, the juju-gui address is retrieved, the GUI is opened. Also ensure the user messages showed on stdout make sense. 2) Execute quickstart again, with the local environment already bootstrapped. Ensure the process completes correctly, and user messages are sane. 3) Destroy the local environment. 4) Bootstrap an ec2 environment with quickstart, ensure the quickstart process completes correctly, the juju-gui address is retrieved, the GUI is opened. Also ensure the user messages showed on stdout make sense. 5) Execute quickstart again, with the ec2 environment already bootstrapped. Ensure the process completes correctly, and user messages are sane. 6) Destroy the ec2 environment. Use juju 1.18. This must be compiled from the juju-core 1.18 branch, which can be found in `lp:juju-core/1.18`. 7) Edit the quickstart/settings.py file included in this branch: set `JUJU_CMD` to point to the juju 1.18 path. 8) Follow steps 1) to 6) again, in order to check that quickstart works well also with Juju 1.18. Done, thank you! https://code.launchpad.net/~frankban/juju-quickstart/new-machine-info/+merge/214317 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 6

Patch Set 2 : Support MachineInfo addresses. #

Total comments: 4

Patch Set 3 : Support MachineInfo addresses. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+506 lines, -140 lines) Patch
M Makefile View 1 1 chunk +2 lines, -1 line 0 comments Download
A [revision details] View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M quickstart/app.py View 3 chunks +19 lines, -7 lines 0 comments Download
M quickstart/models/envs.py View 3 chunks +3 lines, -3 lines 0 comments Download
M quickstart/tests/test_app.py View 11 chunks +209 lines, -109 lines 0 comments Download
M quickstart/tests/test_watchers.py View 1 2 4 chunks +179 lines, -11 lines 0 comments Download
M quickstart/watchers.py View 4 chunks +92 lines, -9 lines 0 comments Download

Messages

Total messages: 7
frankban
Please take a look.
10 years, 1 month ago (2014-04-04 17:47:52 UTC) #1
bac
LGTM. Will QA now. https://codereview.appspot.com/84630043/diff/1/quickstart/models/envs.py File quickstart/models/envs.py (right): https://codereview.appspot.com/84630043/diff/1/quickstart/models/envs.py#newcode444 quickstart/models/envs.py:444: 'The ec2 provider enables you ...
10 years, 1 month ago (2014-04-04 18:24:04 UTC) #2
bac
QA-OK
10 years, 1 month ago (2014-04-04 21:19:04 UTC) #3
frankban
Please take a look. https://codereview.appspot.com/84630043/diff/1/quickstart/models/envs.py File quickstart/models/envs.py (right): https://codereview.appspot.com/84630043/diff/1/quickstart/models/envs.py#newcode444 quickstart/models/envs.py:444: 'The ec2 provider enables you ...
10 years ago (2014-04-07 09:06:26 UTC) #4
rharding
LGTM, couple of questions/comments. I think I follow the first one now. If only you ...
10 years ago (2014-04-07 12:57:50 UTC) #5
frankban
*** Submitted: Support MachineInfo addresses. juju-core 1.18 introduces a change in the mega-watcher: the MachineInfo ...
10 years ago (2014-04-07 13:25:53 UTC) #6
frankban
10 years ago (2014-04-07 13:26:57 UTC) #7
Thank you both!
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b