CRZbulabula commented on PR #17934:
URL: https://github.com/apache/iotdb/pull/17934#issuecomment-4704352086

   Fixed the CI failure in \`IoTDBRemoveDataNodeRegionAllocationIT\` (e75e196).
   
   **Root cause**: after \`kill -9\`-ing the target DataNode, the test 
re-opened a multi-node \`EnvFactory.getConnection()\`. That connection fans 
every read out to *all* DataNodes, including the dead one, so each 
\`executeQuery\` (\`SHOW DATANODES\`, region maps) returned \`[Connection 
Error, null, null, null]\` and failed with \`InconsistentDataException\` at the 
connection site — before the test could exercise the allocation behaviour.
   
   **Fix**: pin all post-kill SQL (both the main statement and the 
allocation-probe connection) to a surviving DataNode via a new 
\`BaseEnv.getConnection(DataNodeWrapper)\` overload, which scopes write *and* 
read to a single live node. This matches the existing framework intent ("This 
is useful when you shut down a dataNode").
   
   The remaining CI reds (\`IoTDBConnectionsIT\` on Windows, 
\`IoTDBPipeClusterIT\` on dual-table-manual-enhanced) are unrelated 
pre-existing flakes — they touch the session and pipe subsystems, not region 
allocation.


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