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

Issue 49640050: provider/local: always use filestorage on CLI

Can't Edit
Can't Publish+Mail
Start Review
Created:
10 years, 3 months ago by axw
Modified:
10 years, 2 months ago
Reviewers:
mp+204169, thumper, rog
Visibility:
Public.

Description

provider/local: always use filestorage on CLI The local provider is modified such that all storage interactions from the CLI go directly to disk, and the provider code no longer starts an httpstorage listener. To achieve this, we no longer store bootstrap-ip in the .jenv, but instead add it to the environment config during bootstrap. Thus, we can use the presence of the attribute to decide whether or not to use the file or http storage. BootstrapStorager no longer needs to be implemented, so EnableBootsrapStorage has been eliminated from the implementation. For old environments, bootstrap-ip will be set in the .jenv and thus httpstorage is used; this is fine, as long as the machine agent is running. There's an edge case that will no longer work, where the environment is bootstrapped but machine-0 agent is not running. In this case, storage is inaccessible. There are some other drive-by fixes to tests that improve isolation, and some redundant tests relating to the old sudo behaviour are removed. All tests now pass with or without a local provider running on the machine. Fixes lp:1271672 https://code.launchpad.net/~axwalk/juju-core/local-provider-testability/+merge/204169 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 6

Patch Set 2 : provider/local: always use filestorage on CLI #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+102 lines, -173 lines) Patch
A [revision details] View 1 1 chunk +2 lines, -0 lines 0 comments Download
M provider/local/config.go View 1 chunk +5 lines, -11 lines 0 comments Download
M provider/local/config_test.go View 3 chunks +5 lines, -66 lines 0 comments Download
M provider/local/environ.go View 1 8 chunks +49 lines, -73 lines 0 comments Download
M provider/local/environ_test.go View 1 chunk +5 lines, -0 lines 0 comments Download
M provider/local/environprovider.go View 5 chunks +13 lines, -2 lines 0 comments Download
M provider/local/environprovider_test.go View 1 chunk +4 lines, -1 line 1 comment Download
M provider/local/export_test.go View 1 2 chunks +7 lines, -10 lines 0 comments Download
M provider/local/instance.go View 2 chunks +2 lines, -2 lines 0 comments Download
M provider/local/local_test.go View 1 chunk +10 lines, -8 lines 0 comments Download

Messages

Total messages: 4
axw
Please take a look.
10 years, 3 months ago (2014-01-31 09:03:13 UTC) #1
rog
LGTM although I'd like a second opinion from someone that's more familiar with local provider ...
10 years, 2 months ago (2014-02-03 09:37:40 UTC) #2
axw
Please take a look. https://codereview.appspot.com/49640050/diff/1/provider/local/environ.go File provider/local/environ.go (right): https://codereview.appspot.com/49640050/diff/1/provider/local/environ.go#newcode235 provider/local/environ.go:235: // continue on to set ...
10 years, 2 months ago (2014-02-11 07:57:23 UTC) #3
thumper
10 years, 2 months ago (2014-02-12 02:17:44 UTC) #4
LGTM

https://codereview.appspot.com/49640050/diff/20001/provider/local/environprov...
File provider/local/environprovider_test.go (left):

https://codereview.appspot.com/49640050/diff/20001/provider/local/environprov...
provider/local/environprovider_test.go:59: c.Skip("fails if local provider
running already")
\o/
Sign in to reply to this message.

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