Qi Zhao
e07e93b00e
Merge pull request #358 from Sajmani/work
...
grpc: make trace.FromContext work, and record handler status in traces
2015-09-28 23:29:59 -07:00
Sameer Ajmani
86db82df28
add TODO to fix trace
2015-09-28 10:22:26 -04:00
iamqizhao
d39eb0802f
bug fix: do not access RemoteAddr on nil net.Conn
2015-09-24 18:44:03 -07:00
iamqizhao
efb129eb20
bug fix: do not access RemoteAddr on nil net.Conn
2015-09-24 18:41:56 -07:00
iamqizhao
60c363f984
bug fix: do not access RemoteAddr on nil net.Conn
2015-09-24 18:39:38 -07:00
Sameer Ajmani
ee98c48bb4
Incorporate dsymonds' comments.
...
Fix another bug: cancel the Context provided to an RPC server handler
as soon as that handler returns, so that goroutines started by that
handler can detect that the handler is done and exit. Without this
fix, goroutines started by a handler will keep running, unless the
handler itself arranges to cancel the context.
2015-09-23 22:17:37 -04:00
Sameer Ajmani
b6c9c5a70f
grpc: record the description of the status returned by server RPC
...
handlers in request traces, and mark the trace as an error if the
status is not OK.
Install the trace into the Context passed to server handlers using
trace.NewContext, so that code in the server handlers can annotate the
trace using trace.FromContext.
2015-09-23 17:07:35 -04:00
Sameer Ajmani
980b4c6d05
grpc: restore changes after sync
...
Change-Id: I97f0c77f95086301202d0fe4ca477ae6e22dd0b5
2015-09-23 15:18:41 -04:00
iamqizhao
125950284c
separate auth info from normal metadata
2015-08-26 11:30:43 -07:00
iamqizhao
d12ff72146
allow access of some info of client certificate
2015-08-21 15:49:53 -07:00
Sameer Ajmani
7c57a23f2d
grpc: rename "Recv" trace family to "grpc.Recv".
2015-08-09 23:24:53 -04:00
iamqizhao
48f64961c0
fix a bug in the PR#264
2015-07-28 20:04:28 -07:00
yangzhouhan
75cfec3f72
fix a condition bug
2015-07-28 18:26:53 -07:00
yangzhouhan
0231ff14bc
remove duplicate check
2015-07-28 18:11:22 -07:00
yangzhouhan
2574b59392
change a comment
2015-07-28 17:33:42 -07:00
yangzhouhan
d90cbe84e6
fix trace set error bugs
2015-07-28 17:18:35 -07:00
yangzhouhan
3616d6be54
fix trace setError
2015-07-28 15:27:46 -07:00
yangzhouhan
82323098b5
remove the extra argu
2015-07-28 13:57:37 -07:00
yangzhouhan
a3dce46030
making trace as an error when error occurs and fix the format
2015-07-28 10:13:40 -07:00
yangzhouhan
a747bc19d9
fix a typo
2015-07-27 14:50:10 -07:00
yangzhouhan
6c8ca3d564
minor change
2015-07-27 14:36:42 -07:00
yangzhouhan
845510e440
add server side tracing
2015-07-27 14:33:17 -07:00
iamqizhao
9738b8b68c
add the sanity check back and refactor
2015-06-12 17:31:53 -07:00
iamqizhao
7b318285c9
remove a sanity check to give more flexibility to host a service. It loses some safety though.
2015-06-12 11:23:39 -07:00
iamqizhao
a3731d046f
only 1 credentials on server
2015-05-12 18:08:36 -07:00
iamqizhao
3617cd5ab3
revert handshaker changes
2015-05-12 17:59:20 -07:00
Peter Edge
7c025e8694
move log package references to grpclog
2015-05-09 11:43:59 +02:00
Peter Edge
101c1e1935
change log package references to grpc/log
2015-05-09 01:16:40 +02:00
iamqizhao
c90971aee7
fix a typo
2015-04-30 17:59:40 -07:00
iamqizhao
c3da701487
gofmt -w
2015-04-30 16:36:21 -07:00
iamqizhao
c6f6e4701d
Add a handshaker option to server
2015-04-30 16:30:48 -07:00
iamqizhao
0f85408fd4
Eliminate proto.Unmarshal in the generated code
2015-04-27 14:47:09 -07:00
iamqizhao
571bcddd7c
Add cancel_after_begin and cancel_afer_first_response test cases
2015-04-22 15:04:17 -07:00
iamqizhao
3259049490
fix some typos and run gofmt
2015-04-17 13:50:18 -07:00
iamqizhao
c7b9fa27dc
addressed some comments
2015-04-01 14:22:53 -07:00
iamqizhao
bec42c09aa
gofmt
2015-04-01 14:05:38 -07:00
iamqizhao
9a5de0e954
make Codec configurable when creating grpc.ClientConn and grpc.Server
2015-04-01 14:02:26 -07:00
iamqizhao
8b08b2d7b2
Interface change to accommodate the support of non-protobuf data formats
2015-03-25 15:18:07 -07:00
iamqizhao
85034d5828
fix double wrapping of rpc status
2015-03-05 18:52:06 -08:00
iamqizhao
c42573b827
improve error logging
2015-02-25 16:33:12 -08:00
Matt T. Proud
a720ae6f48
Make error conveyance more idiomatic.
...
This commit applies two bulk changes to the grpc error reporting
mechanisms:
(1.) Error strings for errors that originate within grpc are prefixed
with the package name for better clarity for where they originate
since they could percolate up in the users call chains to the
originator.
(2.) Errors that are, in fact, singletons have been converted from
fmt.Errorf to errors.New and assigned as package-level variables.
This bodes particularly well for enabling API customers to elect to
handle these errors upon receipt via equality comparison. This had
been previous impossible with the original API.
Supplementarily, ``gofmt -w -s=true`` has been run on the repository to
cleanup residual defects, and it has detected and repaired a few.
TEST=Manual go test ./...
2015-02-19 13:17:17 +01:00
iamqizhao
634392a1c6
Remove the 2nd RecvProto in the generated code for client streaming
2015-02-18 22:18:01 -08:00
iamqizhao
fe60321708
Fix some comments
2015-02-13 16:43:51 -08:00
David Symonds
416f68f4b3
Update import paths to use the new official location of the Go gRPC package.
2015-02-09 11:46:20 +11:00
David Symonds
9e789c396b
Rename top level package from "rpc" to "grpc".
...
Also move the nascent package doc to doc.go.
2015-02-09 11:45:33 +11:00
David Symonds
e71095e0ec
Move source files up one level.
...
The top-level directory in this repository is going to be
the main "grpc" package.
2015-02-09 11:33:38 +11:00