We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
代码镇楼:
public <ReqT, RespT> ClientCall<ReqT, RespT> interceptCall(MethodDescriptor<ReqT, RespT> methodDescriptor, CallOptions callOptions, Channel channel) { String resourceName = methodDescriptor.getFullMethodName(); Entry entry = null; try { entry = SphU.entry(resourceName, EntryType.OUT); // Allow access, forward the call. return new ForwardingClientCall.SimpleForwardingClientCall<ReqT, RespT>( channel.newCall(methodDescriptor, callOptions)) { @Override public void start(Listener<RespT> responseListener, Metadata headers) { super.start(new SimpleForwardingClientCallListener<RespT>(responseListener) { @Override public void onReady() { super.onReady(); } @Override public void onClose(Status status, Metadata trailers) { super.onClose(status, trailers); // Record the exception metrics. if (!status.isOk()) { recordException(status.asRuntimeException()); } } }, headers); } @Override public void cancel(@Nullable String message, @Nullable Throwable cause) { super.cancel(message, cause); // Record the exception metrics. recordException(cause); } }; } catch (BlockException e) { // Flow control threshold exceeded, block the call. return new ClientCall<ReqT, RespT>() { @Override public void start(Listener<RespT> responseListener, Metadata headers) { responseListener.onClose(FLOW_CONTROL_BLOCK, new Metadata()); } @Override public void request(int numMessages) { } @Override public void cancel(@Nullable String message, @Nullable Throwable cause) { } @Override public void halfClose() { } @Override public void sendMessage(ReqT message) { } }; } finally { if (entry != null) { entry.exit(); } } }
grpc adapter中在finally方法中调用的entry.exit(), 那么问题来了,先exit了,然后在cancel方法中recordException,此时entry已经退出了,那么这个exception将不能被正确的记录。暂时没想到什么处理办法~~~惆怅
The text was updated successfully, but these errors were encountered:
Hi, this is a known issue. There's already a PR pending. You can refer to: #289, #291
Sorry, something went wrong.
@sczyh30 thank u~~
[ISSUE alibaba#396]Use separated thread pool and add monitor tools fo…
efa8e45
…r transactional message (alibaba#397) * Use separate threadpool and add monitor tools for transaction * Modify log level
No branches or pull requests
代码镇楼:
grpc adapter中在finally方法中调用的entry.exit(), 那么问题来了,先exit了,然后在cancel方法中recordException,此时entry已经退出了,那么这个exception将不能被正确的记录。暂时没想到什么处理办法~~~惆怅
The text was updated successfully, but these errors were encountered: