bschuchardt commented on a change in pull request #6392:
URL: https://github.com/apache/geode/pull/6392#discussion_r623425366
##########
File path:
geode-core/src/main/java/org/apache/geode/distributed/internal/ReplyMessage.java
##########
@@ -309,11 +316,17 @@ public void fromData(DataInput in,
if (testFlag(status, PROCESSOR_ID_FLAG)) {
this.processorId = in.readInt();
}
- if (testFlag(status, EXCEPTION_FLAG)) {
- this.returnValue = DataSerializer.readObject(in);
- this.returnValueIsException = true;
- } else if (testFlag(status, OBJECT_FLAG)) {
- this.returnValue = DataSerializer.readObject(in);
+ try {
+ if (testFlag(status, EXCEPTION_FLAG)) {
+ this.returnValue = context.getDeserializer().readObject(in);
+ this.returnValueIsException = true;
+ } else if (testFlag(status, OBJECT_FLAG)) {
+ this.returnValue = context.getDeserializer().readObject(in);
+ this.returnValueIsException = (returnValue instanceof ReplyException);
+ }
+ } catch (IOException e) {
Review comment:
I could narrow it down, but it was very surprising to me that a "read"
operation would throw a WriteAbortedException and I wanted to cover all the
bases.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]