You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2020/12/06 03:12:14 UTC
[GitHub] [shardingsphere] wgy8283335 opened a new pull request #8512: Modify prevalidate and post validate method.
wgy8283335 opened a new pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512
Fixes #7531.
Changes proposed in this pull request:
- refactor: modify prevalidate and post validate method.
-
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] wgy8283335 commented on a change in pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
wgy8283335 commented on a change in pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#discussion_r539865600
##########
File path: shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-route/src/main/java/org/apache/shardingsphere/sharding/route/engine/validator/dml/impl/ShardingInsertStatementValidator.java
##########
@@ -90,5 +94,8 @@ private boolean isAllSameTables(final Collection<String> tableNames) {
@Override
public void postValidate(final InsertStatement sqlStatement, final RouteContext routeContext) {
+ if (needCheckShardingKey) {
+ Preconditions.checkState(routeContext.getRouteUnits().size() > 0, "Sharding value must same with subquery.");
Review comment:
I'd like to change the variable name.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-744014444
@wgy8283335 Great job, merged. π
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] codecov-io commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-742275594
# [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=h1) Report
> Merging [#8512](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=desc) (02b1a4a) into [master](https://codecov.io/gh/apache/shardingsphere/commit/31fb74fd516b5064b0ceb70e62be58bfd2c6945a?el=desc) (31fb74f) will **decrease** coverage by `1.23%`.
> The diff coverage is `70.00%`.
[](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #8512 +/- ##
============================================
- Coverage 73.46% 72.22% -1.24%
+ Complexity 603 602 -1
============================================
Files 1508 1545 +37
Lines 23905 24533 +628
Branches 4224 4328 +104
============================================
+ Hits 17561 17719 +158
- Misses 5184 5656 +472
+ Partials 1160 1158 -2
```
| [Impacted Files](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=tree) | Coverage Ξ | Complexity Ξ | |
|---|---|---|---|
| [...tor/dml/impl/ShardingInsertStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL2ltcGwvU2hhcmRpbmdJbnNlcnRTdGF0ZW1lbnRWYWxpZGF0b3IuamF2YQ==) | `79.31% <0.00%> (-5.88%)` | `0.00 <0.00> (ΓΈ)` | |
| [...e/validator/dml/ShardingDMLStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL1NoYXJkaW5nRE1MU3RhdGVtZW50VmFsaWRhdG9yLmphdmE=) | `70.68% <100.00%> (ΓΈ)` | `1.00 <0.00> (ΓΈ)` | |
| [...tor/dml/impl/ShardingSelectStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL2ltcGwvU2hhcmRpbmdTZWxlY3RTdGF0ZW1lbnRWYWxpZGF0b3IuamF2YQ==) | `100.00% <100.00%> (ΓΈ)` | `0.00 <0.00> (ΓΈ)` | |
| [...a/executor/sql/execute/engine/raw/RawExecutor.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtaW5mcmEvc2hhcmRpbmdzcGhlcmUtaW5mcmEtZXhlY3V0b3Ivc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL2luZnJhL2V4ZWN1dG9yL3NxbC9leGVjdXRlL2VuZ2luZS9yYXcvUmF3RXhlY3V0b3IuamF2YQ==) | `0.00% <0.00%> (-87.50%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...initializer/impl/StandardBootstrapInitializer.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtcHJveHkvc2hhcmRpbmdzcGhlcmUtcHJveHktYm9vdHN0cmFwL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9wcm94eS9pbml0aWFsaXplci9pbXBsL1N0YW5kYXJkQm9vdHN0cmFwSW5pdGlhbGl6ZXIuamF2YQ==) | `66.66% <0.00%> (-33.34%)` | `1.00% <0.00%> (ΓΈ%)` | |
| [...caling/core/service/AbstractScalingJobService.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS9zZXJ2aWNlL0Fic3RyYWN0U2NhbGluZ0pvYlNlcnZpY2UuamF2YQ==) | `58.62% <0.00%> (-29.62%)` | `1.00% <0.00%> (ΓΈ%)` | |
| [...dingsphere/scaling/core/utils/ScalingTaskUtil.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS91dGlscy9TY2FsaW5nVGFza1V0aWwuamF2YQ==) | `55.55% <0.00%> (-27.78%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...rdingsphere/scaling/core/utils/ReflectionUtil.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS91dGlscy9SZWZsZWN0aW9uVXRpbC5qYXZh) | `48.57% <0.00%> (-17.15%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...hardingsphere/scaling/mysql/MySQLScalingEntry.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLW15c3FsL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9zY2FsaW5nL215c3FsL015U1FMU2NhbGluZ0VudHJ5LmphdmE=) | `88.88% <0.00%> (-11.12%)` | `1.00% <0.00%> (ΓΈ%)` | |
| [...ere/scaling/postgresql/PostgreSQLScalingEntry.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLXBvc3RncmVzcWwvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvcG9zdGdyZXNxbC9Qb3N0Z3JlU1FMU2NhbGluZ0VudHJ5LmphdmE=) | `88.88% <0.00%> (-11.12%)` | `1.00% <0.00%> (ΓΈ%)` | |
| ... and [187 more](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Ξ = absolute <relative> (impact)`, `ΓΈ = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=footer). Last update [31fb74f...02b1a4a](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] wgy8283335 commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
wgy8283335 commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-739505662
@strongduanmu Hi, could you review my code?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] tristaZero commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
tristaZero commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-740351693
Hi @strongduanmu , Ping here.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-740530388
> @strongduanmu Hi, could you review my code?
@wgy8283335 @tristaZero Sorry for the late reply π
, I will review this pr today.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] codecov-io edited a comment on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-742275594
# [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=h1) Report
> Merging [#8512](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=desc) (abd662e) into [master](https://codecov.io/gh/apache/shardingsphere/commit/31fb74fd516b5064b0ceb70e62be58bfd2c6945a?el=desc) (31fb74f) will **decrease** coverage by `1.51%`.
> The diff coverage is `70.00%`.
[](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #8512 +/- ##
============================================
- Coverage 73.46% 71.94% -1.52%
+ Complexity 603 599 -4
============================================
Files 1508 1554 +46
Lines 23905 24750 +845
Branches 4224 4366 +142
============================================
+ Hits 17561 17807 +246
- Misses 5184 5757 +573
- Partials 1160 1186 +26
```
| [Impacted Files](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=tree) | Coverage Ξ | Complexity Ξ | |
|---|---|---|---|
| [...tor/dml/impl/ShardingInsertStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL2ltcGwvU2hhcmRpbmdJbnNlcnRTdGF0ZW1lbnRWYWxpZGF0b3IuamF2YQ==) | `79.31% <0.00%> (-5.88%)` | `0.00 <0.00> (ΓΈ)` | |
| [...e/validator/dml/ShardingDMLStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL1NoYXJkaW5nRE1MU3RhdGVtZW50VmFsaWRhdG9yLmphdmE=) | `70.68% <100.00%> (ΓΈ)` | `1.00 <0.00> (ΓΈ)` | |
| [...tor/dml/impl/ShardingSelectStatementValidator.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtZmVhdHVyZXMvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmcvc2hhcmRpbmdzcGhlcmUtc2hhcmRpbmctcm91dGUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nL3JvdXRlL2VuZ2luZS92YWxpZGF0b3IvZG1sL2ltcGwvU2hhcmRpbmdTZWxlY3RTdGF0ZW1lbnRWYWxpZGF0b3IuamF2YQ==) | `100.00% <100.00%> (ΓΈ)` | `0.00 <0.00> (ΓΈ)` | |
| [...a/executor/sql/execute/engine/raw/RawExecutor.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtaW5mcmEvc2hhcmRpbmdzcGhlcmUtaW5mcmEtZXhlY3V0b3Ivc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL2luZnJhL2V4ZWN1dG9yL3NxbC9leGVjdXRlL2VuZ2luZS9yYXcvUmF3RXhlY3V0b3IuamF2YQ==) | `0.00% <0.00%> (-87.50%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...initializer/impl/StandardBootstrapInitializer.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtcHJveHkvc2hhcmRpbmdzcGhlcmUtcHJveHktYm9vdHN0cmFwL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9wcm94eS9pbml0aWFsaXplci9pbXBsL1N0YW5kYXJkQm9vdHN0cmFwSW5pdGlhbGl6ZXIuamF2YQ==) | `66.66% <0.00%> (-33.34%)` | `1.00% <0.00%> (ΓΈ%)` | |
| [...caling/core/service/AbstractScalingJobService.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS9zZXJ2aWNlL0Fic3RyYWN0U2NhbGluZ0pvYlNlcnZpY2UuamF2YQ==) | `58.62% <0.00%> (-29.62%)` | `1.00% <0.00%> (ΓΈ%)` | |
| [...dingsphere/scaling/core/utils/ScalingTaskUtil.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS91dGlscy9TY2FsaW5nVGFza1V0aWwuamF2YQ==) | `55.55% <0.00%> (-27.78%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...rdingsphere/scaling/core/utils/ReflectionUtil.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS91dGlscy9SZWZsZWN0aW9uVXRpbC5qYXZh) | `48.57% <0.00%> (-17.15%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...ontext/metadata/impl/StandardMetaDataContexts.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtaW5mcmEvc2hhcmRpbmdzcGhlcmUtaW5mcmEtY29udGV4dC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvaW5mcmEvY29udGV4dC9tZXRhZGF0YS9pbXBsL1N0YW5kYXJkTWV0YURhdGFDb250ZXh0cy5qYXZh) | `84.61% <0.00%> (-15.39%)` | `0.00% <0.00%> (ΓΈ%)` | |
| [...osition/resume/ResumeBreakPointManagerFactory.java](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc2NhbGluZy9zaGFyZGluZ3NwaGVyZS1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NjYWxpbmcvY29yZS9qb2IvcG9zaXRpb24vcmVzdW1lL1Jlc3VtZUJyZWFrUG9pbnRNYW5hZ2VyRmFjdG9yeS5qYXZh) | `75.00% <0.00%> (-12.50%)` | `0.00% <0.00%> (ΓΈ%)` | |
| ... and [217 more](https://codecov.io/gh/apache/shardingsphere/pull/8512/diff?src=pr&el=tree-more) | |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Ξ = absolute <relative> (impact)`, `ΓΈ = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=footer). Last update [31fb74f...abd662e](https://codecov.io/gh/apache/shardingsphere/pull/8512?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu merged pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
strongduanmu merged pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] tristaZero commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
tristaZero commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-743030608
Hi, How is it going now?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu commented on a change in pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on a change in pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#discussion_r538525316
##########
File path: shardingsphere-features/shardingsphere-sharding/shardingsphere-sharding-route/src/main/java/org/apache/shardingsphere/sharding/route/engine/validator/dml/impl/ShardingInsertStatementValidator.java
##########
@@ -90,5 +94,8 @@ private boolean isAllSameTables(final Collection<String> tableNames) {
@Override
public void postValidate(final InsertStatement sqlStatement, final RouteContext routeContext) {
+ if (needCheckShardingKey) {
+ Preconditions.checkState(routeContext.getRouteUnits().size() > 0, "Sharding value must same with subquery.");
Review comment:
Why this check condition is different from the check condition in `ShardingSelectStatementValidator`? π€
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu commented on pull request #8512: Modify prevalidate and post validate method.
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on pull request #8512:
URL: https://github.com/apache/shardingsphere/pull/8512#issuecomment-743237543
> Hi, How is it going now?
@tristaZero I'm very sorry that I couldn't review the code and communicate with @wgy8283335 in time due to my busy work recently. π I will try to communicate with @wgy8283335 to complete the task this weekend.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org