>From Michael Blow <[email protected]>: Attention is currently required from: Hussain Towaileb.
Michael Blow has posted comments on this change by Hussain Towaileb. ( https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/20485?usp=email ) Change subject: [ASTERIXDB-3657][FAIL]: handle non-serialize exceptions ...................................................................... Patch Set 3: (3 comments) File asterixdb/asterix-app/src/main/java/org/apache/asterix/hyracks/bootstrap/CCApplication.java: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/20485/comment/3eabd949_b9008950?usp=email : PS3, Line 165: registerReplacement(BlobStorageException.class, o -> new SerializableExceptionProxy((Throwable) o)); ```suggestion registerReplacement(BlobStorageException.class, SerializableExceptionProxy::new); ``` ...and change the SerializableExceptionProxy ctor to accept Object- that is no less safe than this- both will result in the ClassCastException if the object is not instance of Throwable... File hyracks-fullstack/hyracks/hyracks-api/src/main/java/org/apache/hyracks/api/util/JavaSerializationUtils.java: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/20485/comment/958456e5_b87870cd?usp=email : PS3, Line 168: Function<Object, Object> replacementFunction = replacements.get(object.getClass()); : if (replacementFunction != null) { : return replacementFunction.apply(object); : } : return super.replaceObject(object); : ```suggestion return replacements .getOrDefault(object.getClass(), super::replaceObject) .apply(object); ``` My friend ChatGPT said this would be more compact... https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/20485/comment/6f74cd68_c57960c2?usp=email : PS3, Line 180: Throwable as mentioned elsewhere, if you change this to Object, you can use the more compact `SerializableExceptionProxy::new` during registration... -- To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/20485?usp=email To unsubscribe, or for help writing mail filters, visit https://asterix-gerrit.ics.uci.edu/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: asterixdb Gerrit-Branch: phoenix Gerrit-Change-Id: I55e69623068a6c1759803cc699417021910237fd Gerrit-Change-Number: 20485 Gerrit-PatchSet: 3 Gerrit-Owner: Hussain Towaileb <[email protected]> Gerrit-Reviewer: Anon. E. Moose #1000171 Gerrit-Reviewer: Jenkins <[email protected]> Gerrit-Reviewer: Michael Blow <[email protected]> Gerrit-Attention: Hussain Towaileb <[email protected]> Gerrit-Comment-Date: Tue, 14 Oct 2025 18:05:10 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No
