minal-kyada commented on code in PR #4556:
URL: https://github.com/apache/cassandra/pull/4556#discussion_r2802628489
##########
src/java/org/apache/cassandra/service/WriteResponseHandler.java:
##########
@@ -58,6 +61,12 @@ public WriteResponseHandler(ReplicaPlan.ForWrite
replicaPlan, WriteType writeTyp
public void onResponse(Message<T> m)
{
+ if (m != null)
Review Comment:
I mistakenly thought that I was resetting the messageParams before calling
the handler method, because MP are in thread-local, they won't be accessible in
handler!
But I just realized, that I reset them in finally block and handler is
called before that, which means it still has MP, and the handler can access MP
from thread-local, and I can achieve unified handling!
I was skeptical about the thread-local working. But, I tested the changes.
looks like handler gets the MP and it is propagated correctly to the caller.
So, it works fine!
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]