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

Issue 88350043: HA: upgrade upstart and initiate replset (Closed)

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

Description

HA: upgrade upstart and initiate replset The machine agent will now upgrade the Mongo upstart script and initiate the replicaset when upgrading from a version prior to 1.19.0. Tested upgrading 1.18.1 to 1.19.1 with and without HA enabled; tested straight bootstrap to 1.19.1 with and without HA enabled. https://code.launchpad.net/~axwalk/juju-core/lp1306902-ha-upgrade/+merge/215999 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 6

Patch Set 2 : HA: upgrade upstart and initiate replset #

Patch Set 3 : HA: upgrade upstart and initiate replset #

Unified diffs Side-by-side diffs Delta from patch set Stats (+269 lines, -179 lines) Patch
A [revision details] View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M agent/format-1.18.go View 1 2 3 chunks +7 lines, -4 lines 0 comments Download
M agent/mongo/mongo.go View 1 2 2 chunks +4 lines, -7 lines 0 comments Download
M cmd/jujud/bootstrap.go View 1 2 3 chunks +6 lines, -4 lines 0 comments Download
M cmd/jujud/machine.go View 1 2 3 chunks +97 lines, -29 lines 0 comments Download
M cmd/jujud/machine_test.go View 1 2 10 chunks +18 lines, -8 lines 0 comments Download
M worker/peergrouper/desired_test.go View 1 1 chunk +0 lines, -6 lines 0 comments Download
worker/peergrouper/initiate.go View 1 1 chunk +76 lines, -0 lines 0 comments Download
worker/peergrouper/initiate.go View 1 2 1 chunk +0 lines, -76 lines 0 comments Download
worker/peergrouper/initiate_test.go View 1 1 chunk +0 lines, -45 lines 0 comments Download
worker/peergrouper/initiate_test.go View 1 2 1 chunk +45 lines, -0 lines 0 comments Download
worker/peergrouper/suite_test.go View 1 1 chunk +14 lines, -0 lines 0 comments Download

Messages

Total messages: 3
axw
Please take a look.
10 years ago (2014-04-16 04:14:59 UTC) #1
rog
Looks great in general, modulo a few minor suggestions below. I'd like to take a ...
10 years ago (2014-04-16 10:15:03 UTC) #2
axw
10 years ago (2014-04-16 23:59:56 UTC) #3
https://codereview.appspot.com/88350043/diff/1/agent/mongo/mongo.go
File agent/mongo/mongo.go (right):

https://codereview.appspot.com/88350043/diff/1/agent/mongo/mongo.go#newcode202
agent/mongo/mongo.go:202: if service.Running() {
On 2014/04/16 10:15:04, rog wrote:
> I don't think this condition is necessary - Service.Stop checks whether the
> service is running as a matter of course.

Thanks, I was assuming the same behaviour as "service stop".

https://codereview.appspot.com/88350043/diff/1/cmd/jujud/machine.go
File cmd/jujud/machine.go (right):

https://codereview.appspot.com/88350043/diff/1/cmd/jujud/machine.go#newcode433
cmd/jujud/machine.go:433: // shouldEnableHA returns whether HA should be
enabled.
On 2014/04/16 10:15:04, rog wrote:
> s/returns/reports/
> 
> (standard phrasing)

Done.

https://codereview.appspot.com/88350043/diff/1/cmd/jujud/machine.go#newcode452
cmd/jujud/machine.go:452: withHA := shouldEnableHA(agentConfig)
On 2014/04/16 10:15:04, rog wrote:
> perhaps factor out lines 447 to 504 into a separate function,
> say MachineAgent.ensureMongoServer(agentConfig agent.Config) error
> 
> ?

Done.
Sign in to reply to this message.

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