Skip to content

Commit

Permalink
Merge pull request #129 from forcedotcom/sonal/28022023
Browse files Browse the repository at this point in the history
@W-12606762: fixing grpc dependency conflict and removed 5min timeout on grpc call
  • Loading branch information
soaggarwal authored Feb 28, 2023
2 parents aeb6b11 + c26eaa9 commit 75ec3b7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 4 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,10 @@
<pattern>io.netty</pattern>
<shadedPattern>${shadeBase}.io.netty</shadedPattern>
</relocation>
<relocation>
<pattern>io.grpc</pattern>
<shadedPattern>${shadeBase}.io.grpc</shadedPattern>
</relocation>
</relocations>
<filters>
<filter>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ public class QueryGrpcExecutor extends QueryTokenExecutor {

private static ManagedChannel DEFAULT_CHANNEL = null;
private static final int port = 443;
private static final int timeoutInMin = 5;
// No retry on hyper for now. Fallback to v2 call if receive even one failure from hyper.
private static final int GRPC_MAX_RETRY = 0;
private static final Metadata.Key<String> TRACE_ID_KEY = Metadata.Key.of(Constants.TRACE_ID, Metadata.ASCII_STRING_MARSHALLER);
Expand Down Expand Up @@ -135,7 +134,6 @@ private Iterator<AnsiSqlQueryStreamResponse> executeQuery(String sql, AtomicRefe
QueryServiceGrpc.QueryServiceBlockingStub stub = QueryServiceGrpc.newBlockingStub(channel);
Properties properties = connection.getClientInfo();
return stub
.withDeadlineAfter(timeoutInMin, TimeUnit.MINUTES)
.withMaxInboundMessageSize(MAX_MESSAGE_SIZE)
.withInterceptors(
new GrpcInterceptor(tokenWithTenantUrl, properties),
Expand Down

0 comments on commit 75ec3b7

Please sign in to comment.