I am trying to prototype a java client cache interceptor in AppEngine (java8) and gRPC(1.17.1). The cache interceptor needs to write to AppEngine memcache, so it requires thread be created via
ThreadManager. When I try to supply a custom executor to gRPC via
NettyChannelBuilder or
withExecutor, the call is lost and future get hangs. Note that, all the grpc calls have a deadline of 10 seconds, but I don't see the timeout happening. Seems like gRPC is running into an internal error. AppEngine eventually kills the request with Deadline Exceeded error and no logs are available in the appengine console.
1. In which thread interceptors execute ? Does it use the executor specified in the FutureStub or the event loop ?
2. Besides the executor, what other internal threads gRPC use ? Can I control them to run on the application specified threads ?
3. When thread issues happen, why does the gRPC call hangs, instead of timing out/failing with an error.
Thanks,
Arun.