FlyingZC commented on PR #38782:
URL: https://github.com/apache/shardingsphere/pull/38782#issuecomment-4608222498
**### Decision
- **Merge Verdict: Mergeable**
- **Reviewed Scope:** Reviewed PR latest head
`7b81c7182be07ec59f0040d56697eb5bd33b4b09`; base `master`, local merge-base
`6b32a2c52a0dcda2cd4027dcb1c6a7beda909d3b`. GitHub `/pulls/38782/
files` and local triple-dot diff matched exactly:
`features/sharding/core/src/main/java/org/apache/shardingsphere/sharding/route/strategy/type/standard/StandardShardingStrategy.java`.
- **Not Reviewed Scope:** Full sharding module test suite, Proxy/JDBC E2E,
performance benchmark, and GitHub Actions/CI status were not reviewed.
- **Need Expert Review:** No dedicated security, protocol, dependency, or
dialect parser review required.
### Basis
- This is a behavior-preserving refactor of
`StandardShardingStrategy#doSharding(...)`.
- Before the PR, the public method wrapped the selected precise/range
result with `new CaseInsensitiveSet<>(shardingResult)`.
- After the PR, the precise list path builds a `CaseInsensitiveSet`
directly, and the range path wraps the algorithm result before returning. The
public returned collection remains case-
insensitive for both branches.
- Null filtering and `availableTargetNames.contains(target)` behavior in
the precise path are unchanged.
- No public API/SPI/config changes, no SQL parser syntax changes, no
routing precedence or fallback target changes, and no
`ConcurrentHashMap#computeIfAbsent` usage was introduced.
- Blast-radius check: this shared sharding route strategy can run in JDBC
and Proxy sharding routes across database dialects, but the change only moves
the same case-insensitive result
normalization inside the existing precise/range branches. Existing tests
cover both adjacent branches:
`StandardShardingStrategyTest#assertDoShardingForRangeSharding` and
`StandardShardingStrategyTest#assertDoShardingForListSharding`.
### Verification
- `git diff --check
refs/remotes/apache/master...refs/remotes/apache/pr-38782` exited `0`.
- `./mvnw -pl features/sharding/core -am -DskipITs
-Dsurefire.failIfNoSpecifiedTests=false -Dtest=StandardShardingStrategyTest
test` exited `0`.
- `StandardShardingStrategyTest`: 3 tests run, 0 failures, 0 errors.
- `./mvnw -pl features/sharding/core -am -DskipITs -DskipTests
checkstyle:check -Pcheck -T1C` exited `0`.**
--
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]