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

Issue 6940073: nova double: Rest of HTTP API. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 4 months ago by dimitern
Modified:
11 years, 4 months ago
Reviewers:
mp+140242
Visibility:
Public.

Description

nova double: Rest of HTTP API. This implements the rest of the HTTP API of the Nova testing double: * servers * servers/detail * servers/<id>/os-security-groups * servers/<id>/action (add/removeSecurityGroup; add/removeFloatingIp) * os-security-groups * os-security-group-rules * os-floating-ips There are a few things to change in order to integrate with the Nova client and the local "live" tests, but this will come in a follow-up. https://code.launchpad.net/~dimitern/goose/nova-testing-service-http2/+merge/140242 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 58

Patch Set 2 : nova double: Rest of HTTP API. #

Total comments: 80

Patch Set 3 : nova double: Rest of HTTP API. #

Total comments: 24

Patch Set 4 : nova double: Rest of HTTP API. #

Total comments: 4

Patch Set 5 : nova double: Rest of HTTP API. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1511 lines, -292 lines) Patch
A [revision details] View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M testservices/novaservice/service.go View 1 4 chunks +37 lines, -0 lines 0 comments Download
M testservices/novaservice/service_http.go View 1 2 3 4 5 chunks +628 lines, -183 lines 0 comments Download
M testservices/novaservice/service_http_test.go View 1 2 6 chunks +793 lines, -109 lines 0 comments Download
M testservices/novaservice/service_test.go View 3 chunks +51 lines, -0 lines 0 comments Download

Messages

Total messages: 12
dimitern
Please take a look.
11 years, 4 months ago (2012-12-17 16:35:02 UTC) #1
fwereade
Not a full review, mostly just typos, but a couple of comments nonetheless. https://codereview.appspot.com/6940073/diff/1/testservices/novaservice/service.go File ...
11 years, 4 months ago (2012-12-17 21:04:11 UTC) #2
fwereade
This is quite a big change to follow all at once, so I'm still not ...
11 years, 4 months ago (2012-12-18 10:36:47 UTC) #3
rog
looking reasonable. i think it can be simplified a bit - some comments below. more ...
11 years, 4 months ago (2012-12-18 11:34:40 UTC) #4
jameinel
LGTM. Some tweaks. I think this is a case of post commit review, and having ...
11 years, 4 months ago (2012-12-18 13:12:47 UTC) #5
dimitern
Please take a look. https://codereview.appspot.com/6940073/diff/1/testservices/novaservice/service.go File testservices/novaservice/service.go (right): https://codereview.appspot.com/6940073/diff/1/testservices/novaservice/service.go#newcode384 testservices/novaservice/service.go:384: // allServerSecurtyGroups returns all security ...
11 years, 4 months ago (2012-12-19 13:10:41 UTC) #6
rog
another round of comments. it's looking nice. https://codereview.appspot.com/6940073/diff/6001/testservices/novaservice/service_http.go File testservices/novaservice/service_http.go (right): https://codereview.appspot.com/6940073/diff/6001/testservices/novaservice/service_http.go#newcode40 testservices/novaservice/service_http.go:40: "", all ...
11 years, 4 months ago (2012-12-19 14:05:12 UTC) #7
dimitern
Please take a look. https://codereview.appspot.com/6940073/diff/6001/testservices/novaservice/service_http.go File testservices/novaservice/service_http.go (right): https://codereview.appspot.com/6940073/diff/6001/testservices/novaservice/service_http.go#newcode40 testservices/novaservice/service_http.go:40: "", On 2012/12/19 14:05:12, rog ...
11 years, 4 months ago (2012-12-19 16:48:49 UTC) #8
rog
LGTM with the following points addressed. https://codereview.appspot.com/6940073/diff/15001/testservices/novaservice/service_http.go File testservices/novaservice/service_http.go (right): https://codereview.appspot.com/6940073/diff/15001/testservices/novaservice/service_http.go#newcode40 testservices/novaservice/service_http.go:40: "Unauthorized request", error ...
11 years, 4 months ago (2012-12-19 17:11:36 UTC) #9
dimitern
Please take a look. https://codereview.appspot.com/6940073/diff/15001/testservices/novaservice/service_http.go File testservices/novaservice/service_http.go (right): https://codereview.appspot.com/6940073/diff/15001/testservices/novaservice/service_http.go#newcode40 testservices/novaservice/service_http.go:40: "Unauthorized request", On 2012/12/19 17:11:37, ...
11 years, 4 months ago (2012-12-19 17:36:37 UTC) #10
rog
just a couple of tinies, but LGTM with those addressed. https://codereview.appspot.com/6940073/diff/19001/testservices/novaservice/service_http.go File testservices/novaservice/service_http.go (right): https://codereview.appspot.com/6940073/diff/19001/testservices/novaservice/service_http.go#newcode214 ...
11 years, 4 months ago (2012-12-19 17:43:43 UTC) #11
dimitern
11 years, 4 months ago (2012-12-19 17:51:15 UTC) #12
*** Submitted:

nova double: Rest of HTTP API.

This implements the rest of the HTTP API of the Nova testing double:
* servers
* servers/detail
* servers/<id>/os-security-groups
* servers/<id>/action (add/removeSecurityGroup; add/removeFloatingIp)
* os-security-groups
* os-security-group-rules
* os-floating-ips

There are a few things to change in order to integrate with the Nova client and
the local "live" tests, but this will come in a follow-up.

R=fwereade, rog, jameinel
CC=
https://codereview.appspot.com/6940073

https://codereview.appspot.com/6940073/diff/19001/testservices/novaservice/se...
File testservices/novaservice/service_http.go (right):

https://codereview.appspot.com/6940073/diff/19001/testservices/novaservice/se...
testservices/novaservice/service_http.go:214: func writeResponse(code int, body
[]byte, w http.ResponseWriter, r *http.Request) {
On 2012/12/19 17:43:43, rog wrote:
> i'd put w first here (it's like the receiver of the behaviour - same order as
> w.Write(code, data)), and we can lose the request parameter - it's not used.

Done.

https://codereview.appspot.com/6940073/diff/19001/testservices/novaservice/se...
testservices/novaservice/service_http.go:222: // If JSON mashaling fails, an
error is returned.
On 2012/12/19 17:43:43, rog wrote:
> marshaling
> 
> but i think this line can go. it's not useful info, and it's trivial to see if
> we look at the function body.

Done.
Sign in to reply to this message.

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