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/02/09 01:01:24 UTC
[GitHub] [incubator-shardingsphere] SteNicholas opened a new pull request
#4209: Optimize MySQL DDLStatement Visitor
SteNicholas opened a new pull request #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209
Fixes #3914.
Optimize MySQL DDLStatement visitor:
- Consider to simply `visitCreateTable` in `MySQLDDLVisitor`
- Consider to simply `visitAlterTable` in `MySQLDDLVisitor`
- Consider to simply `createColumnDefinitionSegment` in `MySQLDDLVisitor`
Changes proposed in this pull request:
- Simply `visitCreateTable` in `MySQLDDLVisitor`
- Simply `visitAlterTable` in `MySQLDDLVisitor`
- Simply `createColumnDefinitionSegment` in `MySQLDDLVisitor`
----------------------------------------------------------------
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
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] codecov-io commented on issue #4209:
Optimize MySQL DDLStatement Visitor
Posted by GitBox <gi...@apache.org>.
codecov-io commented on issue #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209#issuecomment-583794190
# [Codecov](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?src=pr&el=h1) Report
> Merging [#4209](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?src=pr&el=desc) into [master](https://codecov.io/gh/apache/incubator-shardingsphere/commit/a0a91df94f50e7db45d01e2db3fb9da66e00a555?src=pr&el=desc) will **decrease** coverage by `0.15%`.
> The diff coverage is `0%`.
[![Impacted file tree graph](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209/graphs/tree.svg?width=650&token=ZvlXpWa7so&height=150&src=pr)](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?src=pr&el=tree)
```diff
@@ Coverage Diff @@
## master #4209 +/- ##
============================================
- Coverage 60.85% 60.69% -0.16%
Complexity 352 352
============================================
Files 1013 1013
Lines 16922 16966 +44
Branches 2983 2991 +8
============================================
Hits 10298 10298
- Misses 5972 6016 +44
Partials 652 652
```
| [Impacted Files](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?src=pr&el=tree) | Coverage Δ | Complexity Δ | |
|---|---|---|---|
| [...dingsphere/sql/parser/visitor/MySQLDDLVisitor.java](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc3FsLXBhcnNlci9zaGFyZGluZ3NwaGVyZS1zcWwtcGFyc2VyLW15c3FsL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9zcWwvcGFyc2VyL3Zpc2l0b3IvTXlTUUxERExWaXNpdG9yLmphdmE=) | `0% <0%> (ø)` | `0 <0> (ø)` | :arrow_down: |
------
[Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?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/incubator-shardingsphere/pull/4209?src=pr&el=footer). Last update [a0a91df...ae40ca2](https://codecov.io/gh/apache/incubator-shardingsphere/pull/4209?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
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] tristaZero merged pull request #4209:
Optimize MySQL DDLStatement Visitor
Posted by GitBox <gi...@apache.org>.
tristaZero merged pull request #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209
----------------------------------------------------------------
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
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] coveralls commented on issue #4209:
Optimize MySQL DDLStatement Visitor
Posted by GitBox <gi...@apache.org>.
coveralls commented on issue #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209#issuecomment-583794348
## Pull Request Test Coverage Report for [Build 9389](https://coveralls.io/builds/28610900)
* **0** of **116** **(0.0%)** changed or added relevant lines in **1** file are covered.
* **4** unchanged lines in **2** files lost coverage.
* Overall coverage decreased (**-0.2%**) to **64.6%**
---
| Changes Missing Coverage | Covered Lines | Changed/Added Lines | % |
| :-----|--------------|--------|---: |
| [shardingsphere-sql-parser/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/visitor/MySQLDDLVisitor.java](https://coveralls.io/builds/28610900/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fvisitor%2FMySQLDDLVisitor.java#L91) | 0 | 116 | 0.0%
<!-- | **Total:** | **0** | **116** | **0.0%** | -->
| Files with Coverage Reduction | New Missed Lines | % |
| :-----|--------------|--: |
| [shardingsphere-sql-parser/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/visitor/MySQLDDLVisitor.java](https://coveralls.io/builds/28610900/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fvisitor%2FMySQLDDLVisitor.java#L223) | 1 | 0% |
| [sharding-orchestration/sharding-orchestration-core/src/main/java/org/apache/shardingsphere/orchestration/internal/util/IpUtils.java](https://coveralls.io/builds/28610900/source?filename=sharding-orchestration%2Fsharding-orchestration-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Forchestration%2Finternal%2Futil%2FIpUtils.java#L65) | 3 | 76.0% |
<!-- | **Total:** | **4** | | -->
| Totals | [![Coverage Status](https://coveralls.io/builds/28610900/badge)](https://coveralls.io/builds/28610900) |
| :-- | --: |
| Change from base [Build 797](https://coveralls.io/builds/28604840): | -0.2% |
| Covered Lines: | 10960 |
| Relevant Lines: | 16966 |
---
##### 💛 - [Coveralls](https://coveralls.io)
----------------------------------------------------------------
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
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] tristaZero commented on issue #4209:
Optimize MySQL DDLStatement Visitor
Posted by GitBox <gi...@apache.org>.
tristaZero commented on issue #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209#issuecomment-583805183
Hi @SteNicholas Thanks for this optimization. It seems this class becomes much better. Your contribution made this class become more clear, not as ugly as ever. Althought more optimization could be done, one point concerns me much is the name of some rules, like `CreateDefinitionClause_`.
Our instruction tells us `CreateDefinitionClause` is standard one, since we visited it in our `Visitor.class`, so i suggest to review any rule name ending with `_` in `MySQLDDLVisitor.java`.
I'd like to see your another PR concerning this. Welcome your opinions. 😃 Good job!
----------------------------------------------------------------
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
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] coveralls edited a comment on issue
#4209: Optimize MySQL DDLStatement Visitor
Posted by GitBox <gi...@apache.org>.
coveralls edited a comment on issue #4209: Optimize MySQL DDLStatement Visitor
URL: https://github.com/apache/incubator-shardingsphere/pull/4209#issuecomment-583794348
## Pull Request Test Coverage Report for [Build 1650](https://coveralls.io/builds/28610916)
* **0** of **116** **(0.0%)** changed or added relevant lines in **1** file are covered.
* **1** unchanged line in **1** file lost coverage.
* Overall coverage decreased (**-0.2%**) to **64.606%**
---
| Changes Missing Coverage | Covered Lines | Changed/Added Lines | % |
| :-----|--------------|--------|---: |
| [shardingsphere-sql-parser/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/visitor/MySQLDDLVisitor.java](https://coveralls.io/builds/28610916/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fvisitor%2FMySQLDDLVisitor.java#L91) | 0 | 116 | 0.0%
<!-- | **Total:** | **0** | **116** | **0.0%** | -->
| Files with Coverage Reduction | New Missed Lines | % |
| :-----|--------------|--: |
| [shardingsphere-sql-parser/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/visitor/MySQLDDLVisitor.java](https://coveralls.io/builds/28610916/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fvisitor%2FMySQLDDLVisitor.java#L223) | 1 | 0% |
<!-- | **Total:** | **1** | | -->
| Totals | [![Coverage Status](https://coveralls.io/builds/28610916/badge)](https://coveralls.io/builds/28610916) |
| :-- | --: |
| Change from base [Build 797](https://coveralls.io/builds/28604840): | -0.2% |
| Covered Lines: | 10961 |
| Relevant Lines: | 16966 |
---
##### 💛 - [Coveralls](https://coveralls.io)
----------------------------------------------------------------
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
With regards,
Apache Git Services