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

Issue 83050045: Generate/set state serving info

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

Description

Generate/set state serving info The bootstrap-state invocation of jujud is modified to generate a shared secret for the Mongo replicaset. This is stored in: $(datadir)/shared-secret. During state initialisation, state serving info (including the shared secret) is stored in state. https://code.launchpad.net/~axwalk/juju-core/jujud-bootstrap-mongo-sharedsecret/+merge/213610 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 4

Patch Set 2 : Generate/set state serving info #

Unified diffs Side-by-side diffs Delta from patch set Stats (+114 lines, -10 lines) Patch
A [revision details] View 1 1 chunk +2 lines, -0 lines 0 comments Download
M agent/bootstrap.go View 1 3 chunks +25 lines, -4 lines 0 comments Download
M agent/bootstrap_test.go View 2 chunks +12 lines, -0 lines 0 comments Download
M agent/mongo/mongo.go View 1 5 chunks +25 lines, -4 lines 0 comments Download
M agent/mongo/mongo_test.go View 2 chunks +9 lines, -0 lines 0 comments Download
M cmd/jujud/bootstrap.go View 3 chunks +14 lines, -0 lines 0 comments Download
M cmd/jujud/bootstrap_test.go View 2 chunks +25 lines, -0 lines 0 comments Download
M environs/cloudinit/cloudinit_test.go View 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 3
axw
Please take a look.
10 years ago (2014-04-01 08:28:00 UTC) #1
rog
LGTM, thanks! https://codereview.appspot.com/83050045/diff/1/agent/bootstrap.go File agent/bootstrap.go (right): https://codereview.appspot.com/83050045/diff/1/agent/bootstrap.go#newcode80 agent/bootstrap.go:80: st.Close() For consideration: there are perhaps enough ...
10 years ago (2014-04-01 08:46:50 UTC) #2
axw
10 years ago (2014-04-01 09:38:32 UTC) #3
Please take a look.

https://codereview.appspot.com/83050045/diff/1/agent/bootstrap.go
File agent/bootstrap.go (right):

https://codereview.appspot.com/83050045/diff/1/agent/bootstrap.go#newcode80
agent/bootstrap.go:80: st.Close()
On 2014/04/01 08:46:51, rog wrote:
> For consideration: there are perhaps enough Close calls here to warrant a
> 
> defer func() {
>    if err != nil {
>        st.Close()
>    }
> }()
> 
> earlier.

Done.

https://codereview.appspot.com/83050045/diff/1/agent/mongo/mongo.go
File agent/mongo/mongo.go (right):

https://codereview.appspot.com/83050045/diff/1/agent/mongo/mongo.go#newcode53
agent/mongo/mongo.go:53: return "", err
On 2014/04/01 08:46:51, rog wrote:
> s/err/fmt.Errorf("cannot read random secret: %v", err)/
> ?

Done.
Sign in to reply to this message.

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