zentol commented on code in PR #24292:
URL: https://github.com/apache/flink/pull/24292#discussion_r1485902184
##########
flink-rpc/flink-rpc-core/src/main/java/org/apache/flink/runtime/rpc/MainThreadValidatorUtil.java:
##########
@@ -45,11 +45,13 @@ public MainThreadValidatorUtil(RpcEndpoint endpoint) {
public void enterMainThread() {
assert (endpoint.currentMainThread.compareAndSet(null,
Thread.currentThread()))
: "The RpcEndpoint has concurrent access from " +
endpoint.currentMainThread.get();
+ endpoint.beforeInvocation();
Review Comment:
We don't need both this and the main thread executor. All the main thread
executor does is throw things into the rpc actor.
I also don't like this being coupled into the main thread validation logic;
and would rather see this being handled in the PekkoRpcActor or encoded into
runnables within the PekkoInvocationHandler.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]