Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(185)

Issue 1637193002: common/prpc, tools/cmd/cproto: prpc client (Closed)

Created:
4 years, 10 months ago by dnj
Modified:
4 years, 10 months ago
CC:
andrew.wang, chromium-reviews, infra-reviews+luci-go_chromium.org, M-A Ruel, tandrii+luci-go_chromium.org, todd
Base URL:
https://github.com/luci/luci-go@prpc-server
Target Ref:
refs/heads/master
Project:
luci-go
Visibility:
Public.

Description

common/prpc, tools/cmd/cproto: prpc client * common/prpc package implements a pRPC Client * tools/cmd/cproto: generate NewXxxPRPCClient functions * move gRPC code <-> HTTP status code mapping from server/prpc to common/prpc R=dnj@chromium.org, vadimsh@chromium.org BUG= Committed: https://github.com/luci/luci-go/commit/46e51273292d7a72a7169e6fe66314e645e0645f

Patch Set 1 #

Patch Set 2 : Small cleanup, add Unavailable to transient list. #

Total comments: 5

Patch Set 3 : Add Context-derived timeout for Client. #

Total comments: 20

Patch Set 4 : Added content bounding code, fixed a lot of nits. #

Patch Set 5 : Deadline => Timeout #

Patch Set 6 : Use correct units. #

Patch Set 7 : Add some content length tests. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+822 lines, -90 lines) Patch
M common/errors/transient.go View 1 2 3 1 chunk +9 lines, -0 lines 0 comments Download
A common/errors/wrap.go View 1 2 3 1 chunk +33 lines, -0 lines 0 comments Download
M common/logging/fields.go View 1 chunk +1 line, -1 line 0 comments Download
M common/prpc/client.go View 1 2 3 4 5 1 chunk +278 lines, -0 lines 0 comments Download
A common/prpc/client_test.go View 1 2 3 4 5 6 1 chunk +252 lines, -0 lines 0 comments Download
A common/prpc/codes.go View 1 2 3 1 chunk +48 lines, -0 lines 0 comments Download
A + common/prpc/generate.go View 1 chunk +0 lines, -1 line 0 comments Download
A + common/prpc/helloworld_test.proto View 1 chunk +1 line, -7 lines 0 comments Download
A common/prpc/helloworld_test.pb_test.go View 1 chunk +60 lines, -0 lines 0 comments Download
A common/prpc/options.go View 1 2 3 1 chunk +85 lines, -0 lines 0 comments Download
A + common/prpc/timeout.go View 1 2 3 chunks +38 lines, -5 lines 0 comments Download
M common/retry/limited.go View 2 chunks +3 lines, -3 lines 0 comments Download
M common/retry/transient.go View 1 chunk +4 lines, -0 lines 0 comments Download
M server/prpc/decoding.go View 1 2 3 chunks +5 lines, -4 lines 0 comments Download
M server/prpc/decoding_test.go View 1 2 3 chunks +5 lines, -4 lines 0 comments Download
D server/prpc/timeout.go View 1 2 1 chunk +0 lines, -65 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 18 (7 generated)
dnj
PTAL. Continued from: https://codereview.chromium.org/1605363002/
4 years, 10 months ago (2016-01-27 00:22:49 UTC) #2
nodir
lgtm
4 years, 10 months ago (2016-01-27 00:24:47 UTC) #3
Vadim Sh.
lgtm with nits https://codereview.chromium.org/1637193002/diff/20001/common/prpc/client.go File common/prpc/client.go (right): https://codereview.chromium.org/1637193002/diff/20001/common/prpc/client.go#newcode102 common/prpc/client.go:102: logging.Debugf(ctx, "RPC %s/%s.%s", c.Host, serviceName, methodName) ...
4 years, 10 months ago (2016-01-27 01:13:54 UTC) #4
dnj (Google)
https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go File common/prpc/client.go (right): https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go#newcode88 common/prpc/client.go:88: // server using the HeaderTimeout heaer. typo will fix.
4 years, 10 months ago (2016-01-27 02:42:54 UTC) #6
dnj (Google)
(vadimsh@, updated w/ Context-based timeout if you'd like to take another look).
4 years, 10 months ago (2016-01-27 02:46:39 UTC) #7
iannucci
lgtm https://codereview.chromium.org/1637193002/diff/40001/common/errors/transient.go File common/errors/transient.go (right): https://codereview.chromium.org/1637193002/diff/40001/common/errors/transient.go#newcode21 common/errors/transient.go:21: var _ Wrap = transientWrapper{} var _ interface ...
4 years, 10 months ago (2016-01-27 02:55:50 UTC) #9
nodir
https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go File common/prpc/client.go (right): https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go#newcode40 common/prpc/client.go:40: HeaderTimeout = "X-Prpc-Grpc-Deadline" was accidentally renamed to deadline? fwiu, ...
4 years, 10 months ago (2016-01-27 03:04:18 UTC) #10
dnj (Google)
PTAL at the content bounding code? https://codereview.chromium.org/1637193002/diff/40001/common/errors/transient.go File common/errors/transient.go (right): https://codereview.chromium.org/1637193002/diff/40001/common/errors/transient.go#newcode21 common/errors/transient.go:21: var _ Wrap ...
4 years, 10 months ago (2016-01-27 03:24:26 UTC) #12
dnj (Google)
https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go File common/prpc/client.go (right): https://codereview.chromium.org/1637193002/diff/40001/common/prpc/client.go#newcode40 common/prpc/client.go:40: HeaderTimeout = "X-Prpc-Grpc-Deadline" On 2016/01/27 03:04:18, nodir wrote: > ...
4 years, 10 months ago (2016-01-27 03:25:53 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1637193002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1637193002/120001
4 years, 10 months ago (2016-01-27 16:44:14 UTC) #16
commit-bot: I haz the power
4 years, 10 months ago (2016-01-27 16:47:59 UTC) #18
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://github.com/luci/luci-go/commit/46e51273292d7a72a7169e6fe66314e645e0645f

Powered by Google App Engine
This is Rietveld 408576698