53 Commits

Author SHA1 Message Date
5fc798be17 Add binary logger option for client and server (#5675)
* Add binary logger option for client and server
2022-10-06 13:36:05 -04:00
02f1a7ac92 grpc: prevent a nil stats handler from causing a panic (#5543) 2022-07-29 10:45:21 -07:00
c402378755 doc: remove comment about obsolete GRPC_GO_RETRY env var (#5495) 2022-07-12 13:36:41 -07:00
ea86bf7497 stats: add support for multiple stats handlers in a single client or server (#5347) 2022-06-03 09:15:50 -07:00
13b378bc45 internal: add global DialOptions and ServerOptions for all clients and servers (#5352) 2022-06-02 16:17:01 -07:00
6c3ccbe89a grpc: remove remaining usages of grpc.WithInsecure() (#5246) 2022-03-17 10:17:03 -07:00
eead9a824c grpc: delete deprecated API WithBalancerName() (#5232) 2022-03-10 13:15:11 -08:00
a73725f42d channelz: include channelz identifier in logs (#5192) 2022-02-23 07:30:06 -08:00
4d58dd98db dialoptions.go: Fix WithBlock godoc (#5073) 2021-12-23 10:56:58 -08:00
8ae11f4622 grpc: minor improvement on WithInsecure() document (#5068) 2021-12-22 11:34:33 -08:00
dd767416a6 grpc: implement WithInsecure() using the insecure package (#4718) 2021-11-09 15:42:07 -08:00
c25a52b769 config: remove retry disable via environment variable (#4922) 2021-11-09 13:06:38 -08:00
3b94303f37 grpc: stabilize WithConnectParams DialOption (#4915) 2021-11-03 13:20:53 -07:00
6e8625df63 doc: promote WithDisableRetry to stable; clarify retry is enabled by default (#4901) 2021-10-26 14:43:44 -07:00
fbf9b56376 grpc: stabilize WithDefaultServiceConfig and improve godoc (#4888) 2021-10-20 09:31:50 -07:00
aaff9e7ab9 grpc: better RFC 3986 compliant target parsing (#4817) 2021-10-14 14:54:02 -07:00
1c598a11a4 Move exponential backoff to DNS resolver from resolver.ClientConn (#4270) 2021-04-20 13:20:09 -04:00
4be647f7f6 internal/resolver/unix: Implemented unix resolver. (#3890) 2020-10-16 11:52:54 -07:00
d9063e7af3 standardized experimental warnings (#3917) 2020-10-02 09:11:08 -07:00
506b773066 Implemented component logging (#3617) 2020-06-26 12:04:47 -07:00
636b0d84dd internal: fix typos (#3581) 2020-05-19 19:24:38 -07:00
4eb418e5b2 balancer: move Balancer and Picker to V2; delete legacy API (#3431) 2020-04-28 14:52:49 -07:00
b02de00073 client: option to surface connection errors to callers (#3430)
This commit allows blocking clients to receive a more informative error
message than "context deadline exceeded", which is especially helpful in
tracking down persistent client misconfiguration (such as an invalid TLS
certificate, an invalid server that's refusing connections, etc.)
2020-04-09 13:45:13 -07:00
e965f2a60b client: add a WithNoProxy dialoption (#3411) 2020-03-26 15:29:40 -07:00
cd74fa23ea internal: remove withResolverBuilder and use WithResolvers instead (#3321) 2020-01-15 08:54:42 -08:00
0083f6eefc client: add WithResolvers options for specifying client-local resolvers (#3320) 2020-01-14 12:44:21 -08:00
c35a580b0c Revert "balancer: move Balancer and Picker to V2; delete legacy… (#3315)
This reverts commit 336cf8d76145dc5ebd517fd9c19e14c6822450b3.
2020-01-13 13:12:55 -08:00
336cf8d761 balancer: move Balancer and Picker to V2; delete legacy API (#3301) 2020-01-10 13:44:48 -08:00
032a3799b2 godoc: clarify WithTimeout deprecation note (#3226)
Tell people to replace Dial + WithTimeout with DialContext + context.WithTimeout.
2019-12-12 13:29:02 -08:00
9f02faeffa credentials: move TLS implementation to a separate file (#3243) 2019-12-11 13:11:24 -08:00
027cd627f8 Fix a data race in resolver_conn_wrapper.go (#3090) 2019-10-14 15:13:33 -07:00
31911ed09e client: add WithConnectParams to configure connection backoff and timeout (#2960)
* Implement missing pieces for connection backoff.

Spec can be found here:
https://github.com/grpc/grpc/blob/master/doc/connection-backoff.md

Summary of changes:
* Added a new type (marked experimental), ConnectParams, which contains
  the knobs defined in the spec (except for minConnectTimeout).
* Added a new API (marked experimental), WithConnectParams() to return a
  DialOption to dial with the provided parameters.
* Added new fields to the implementation of the exponential backoff in
  internal/backoff which mirror the ones in ConnectParams.
* Marked existing APIs WithBackoffMaxDelay() and WithBackoffConfig() as
  deprecated.
* Added a default exponential backoff implementation, for easy use of
  internal callers.

Added a new backoff package which defines the backoff configuration
options, and is used by both the grpc package and the internal/backoff
package. This allows us to have all backoff related options in a
separate package.
2019-10-03 16:47:13 -07:00
24b2fb8959 client: remove option to send RPCs before HTTP/2 handshake is completed (#2904) 2019-07-12 13:37:27 -07:00
12906490e0 docs: clarify "deprecated" to indicate whether some features may be removed in 1.x (#2900)
Also, deprecate WithBalancerName (was experimental).

The decision of whether something may be removed is based on if it was marked experimental as of v1.0/GA or upon its introduction, in accordance with Documentation/versioning.md.
2019-07-11 14:05:18 -07:00
263405c7fe docs: small docs fixed to WithDisableServiceConfig (#2819) 2019-05-16 13:30:58 -07:00
776edd3ba1 interceptor: new APIs for chaining client interceptors. (#2696) 2019-04-15 11:13:34 -07:00
ea5e6da287 service config: default service config (#2686) 2019-04-03 10:50:28 -07:00
d021e89b3f internal: fix Dial_OneBackoffPerRetryGroup (#2689)
* internal: fix Dial_OneBackoffPerRetryGroup

Instead of mutating global variables, switches getMinConnectDeadline to a
dial option.

Fixes #2687.

* rename getMinConnectTimeoutFunc to minConnectTimeout, ditto dial opt
2019-03-20 13:58:29 -06:00
40cb5618f4 dialOption: export WithContextDialer() (#2629)
fixes #2627
2019-02-25 15:22:10 -08:00
ed70822b12 keepalive: apply minimum ping time of 10s to client and 1s to server (#2642)
* keepalive: apply minimum ping time of 10s to client and 1s to server

* review fixes
2019-02-21 13:09:37 -08:00
d14ffaeb5c client: deprecate CallCustomCodec and provide new version using encoding.Codec (#2556) 2019-02-01 10:21:31 -08:00
dfd7708d35 cleanup: use time.Until(t) instead of t.Sub(time.Now) (#2571) 2019-01-15 16:09:50 -08:00
6cc789b34b client: make handshake required 'on' by default, not 'hybrid' (#2565) 2019-01-15 09:19:32 -08:00
5da252b6a6 health check test: prevent double close of hcEnterChan (#2441) 2018-12-13 16:44:36 -08:00
14de8b69c2 WithWaitForHandshake: fix deprecated comment (#2518) 2018-12-10 17:17:24 -08:00
f3eb5bc06e client: add GRPC_GO_REQUIRE_HANDSHAKE options to control connection behavior (#2464)
Possible settings of this environment variable:

- "hybrid" (default; removed after the 1.17 release): do not wait for handshake before considering a connection ready, but wait before considering successful.

- "on" (default after the 1.17 release): wait for handshake before considering a connection ready/successful.

- "off": do not wait for handshake before considering a connection ready/successful.

This setting will be completely removed after the 1.18 release, and "on" will be the only supported behavior.
2018-11-26 15:06:46 -08:00
04ea82009c cleanup: replace "x/net/context" import with "context" (#2439) 2018-11-12 13:30:41 -08:00
105f61423e health: Client LB channel health checking (#2387) 2018-11-01 10:49:35 -07:00
4dedfdc82c credentials: support google default creds (#2315)
Google default creds is a combo of ALTS, TLS and OAuth2. The right set of creds will be picked to use based on environment.

This PR contains:
 - A new `creds.Bundle` type
   - changes to use it in ClientConn and transport
   - dial option to set the bundle for a ClientConn
   - balancer options and NewSubConnOption to set it for SubConn
 - Google default creds implementation by @cesarghali 
 - grpclb changes to use different creds mode for different servers
 - interop client changes for google default creds testing
2018-09-25 13:17:25 -07:00
91c7ef84b5 client: fix FailOnNonTempDialError and add a test for it (#2276) 2018-08-27 10:28:41 -07:00