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

Issue 6443123: jujuc command execution is now mutexed

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 8 months ago by fwereade
Modified:
11 years, 8 months ago
Reviewers:
mp+119480
Visibility:
Public.

Description

jujuc command execution is now mutexed ...because HookContext and RelationContext haven't been designed to be goroutine-safe, and I don't see any major benefits to parallel hook command execution. https://code.launchpad.net/~fwereade/juju-core/server-unparallel-commands/+merge/119480 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 4

Patch Set 2 : jujuc command execution is now mutexed #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -3 lines) Patch
A [revision details] View 1 1 chunk +2 lines, -0 lines 0 comments Download
M cmd/jujuc/server/server.go View 1 4 chunks +6 lines, -2 lines 0 comments Download
M cmd/jujuc/server/server_test.go View 1 5 chunks +30 lines, -1 line 0 comments Download

Messages

Total messages: 3
fwereade
Please take a look.
11 years, 8 months ago (2012-08-14 07:42:42 UTC) #1
niemeyer
LGTM https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server.go File cmd/jujuc/server/server.go (right): https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server.go#newcode47 cmd/jujuc/server/server.go:47: // command will run in parallel. Positively it ...
11 years, 8 months ago (2012-08-16 00:18:42 UTC) #2
fwereade
11 years, 8 months ago (2012-08-18 09:11:57 UTC) #3
*** Submitted:

jujuc command execution is now mutexed

...because HookContext and RelationContext haven't been designed to be
goroutine-safe, and I don't see any major benefits to parallel hook
command execution.

R=niemeyer
CC=
https://codereview.appspot.com/6443123

https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server.go
File cmd/jujuc/server/server.go (right):

https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server.go#newc...
cmd/jujuc/server/server.go:47: // command will run in parallel.
On 2012/08/16 00:18:42, niemeyer wrote:
> Positively it is easier to read:
> 
> // A single command is run at a time.

Done.

https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server_test.go
File cmd/jujuc/server/server_test.go (right):

https://codereview.appspot.com/6443123/diff/1/cmd/jujuc/server/server_test.go...
cmd/jujuc/server/server_test.go:41: <-time.After(50 * time.Millisecond)
On 2012/08/16 00:18:42, niemeyer wrote:
> time.Sleep(...)

Done.
Sign in to reply to this message.

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