Revert "feat: enable retry for zrpc (#1237)" (#1245)

This reverts commit 09eb53f308.
This commit is contained in:
Kevin Wan
2021-11-15 23:30:31 +08:00
committed by GitHub
parent 11c485a5ed
commit 67db40ed4f
4 changed files with 32 additions and 26 deletions

View File

@@ -96,20 +96,21 @@ func TestDepositServer_Deposit(t *testing.T) {
return invoker(ctx, method, req, reply, cc, opts...)
}),
)
retryClient := MustNewClient(
RpcClientConf{
Endpoints: []string{"foo"},
App: "foo",
Token: "bar",
Timeout: 1000,
Retry: true,
},
WithDialOption(grpc.WithContextDialer(dialer())),
WithUnaryClientInterceptor(func(ctx context.Context, method string, req, reply interface{},
cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error {
return invoker(ctx, method, req, reply, cc, opts...)
}),
)
// TODO: enable it in v1.2.4
// retryClient := MustNewClient(
// RpcClientConf{
// Endpoints: []string{"foo"},
// App: "foo",
// Token: "bar",
// Timeout: 1000,
// Retry: true,
// },
// WithDialOption(grpc.WithContextDialer(dialer())),
// WithUnaryClientInterceptor(func(ctx context.Context, method string, req, reply interface{},
// cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error {
// return invoker(ctx, method, req, reply, cc, opts...)
// }),
// )
tarConfClient := MustNewClient(
RpcClientConf{
Target: "foo",
@@ -134,7 +135,8 @@ func TestDepositServer_Deposit(t *testing.T) {
clients := []Client{
directClient,
nonBlockClient,
retryClient,
// TODO: enable it in v1.2.4
// retryClient,
tarConfClient,
targetClient,
}