XianReallyHot-ZZH commented on PR #13762:
URL: https://github.com/apache/ignite/pull/13762#issuecomment-6874305277

   @chesnokoff implemented your idea in a stacked commit (the first solution's 
history is preserved — reverting it recovers the statusCode version, as you 
asked):
   
   - Dropped the feature-gated `statusCode` field, the `CoreFeatureRegistry` 
registration and the wire-compatibility baseline update — the PR no longer 
touches the wire format at all: `GridQueryFailResponse` is field-identical to 
master.
   - Added `SQL_ERROR = 3` to the existing `failCode`; the constructor sets it 
when the error carries an `IgniteSQLException` in its cause chain (checked 
after the existing CANCELLED/RETRY branches, so those keep their current 
priority).
   - The reducer reconstructs `CacheException(mapperFailedMsg, new 
IgniteSQLException(errMsg, UNKNOWN))`; the outer message is byte-identical to 
master.
   
   Old nodes are unaffected: master's `fail()` dispatches unknown fail codes to 
the final `else` (causeless `CacheException`), so an old reducer receiving 
`SQL_ERROR` behaves exactly as today.
   
   Two implicit choices worth stating: a 
`QueryRetryException`/`QueryCancelledException` wrapping an 
`IgniteSQLException` is still classified RETRY/CANCELLED (pre-existing priority 
kept), and the reconstructed cause's message is the map node's top-level 
`errMsg` per your suggestion, not the nested exception's own message.
   
   No information is lost vs the previous approach — the ticket's scenario 
carried `UNKNOWN` on the wire anyway; the existing test (unchanged) still 
passes 2/2. Also rebased on latest master; the `CoreFeatureRegistry` conflict 
is gone along with the registration itself.


-- 
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]

Reply via email to