terrymanu commented on PR #39131:
URL: https://github.com/apache/shardingsphere/pull/39131#issuecomment-5099857414

   Thanks for clarifying. You may remove the current HintManager-specific 
plumbing from `GeneralDQLE2EIT` if it is replaced by a focused JDBC E2E 
regression test. However, please do not remove the actual HintManager scenario 
or leave only the mocked unit test.
   
   The public reproduction confirms that the query succeeds without HintManager 
and fails when `HintManager.setDataSourceName(...)` activates the 
derived-projection path. Therefore, the committed regression test should:
   
   - Use the actual `MySQL + JDBC + tbl` scenario.
   - Call `HintManager.setDataSourceName("tbl")`.
   - Execute:
   
     ```sql
     SELECT T.*, T.status status_new
     FROM t_order T
     WHERE T.order_id = 1000
     ```
   
   - Verify the values returned through bare labels such as `order_id`, 
`user_id`, `status`, and `status_new`.
   - Fail on the merge base and pass with this fix.
   
   Please also ensure that non-target E2E matrices produce zero invocations 
instead of failing. The current provider’s `checkState(!matched.isEmpty())` 
would fail other database, adapter, and scenario combinations. The test-case 
SQL selected by the provider should match the SQL actually executed; the 
non-reproducing JOIN case should not be used merely as a parameter carrier.
   
   One additional implementation point: `expandedMap.size() == 
resultSetMetaData.getColumnCount()` does not prove that both sides contain the 
same labels. Please cover the equal-size-but-different-label case and 
supplement missing metadata labels as well.


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