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 2022/08/08 11:13:54 UTC
[GitHub] [shardingsphere] azexcy opened a new pull request, #19979: Refactor GovernanceRepositoryAPI for common usage
azexcy opened a new pull request, #19979:
URL: https://github.com/apache/shardingsphere/pull/19979
Fixes #19887.
Changes proposed in this pull request:
- Refactor GovernanceRepositoryAPI
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] sandynz merged pull request #19979: Refactor GovernanceRepositoryAPI for common usage
Posted by GitBox <gi...@apache.org>.
sandynz merged PR #19979:
URL: https://github.com/apache/shardingsphere/pull/19979
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] sandynz commented on a diff in pull request #19979: Refactor GovernanceRepositoryAPI for common usage
Posted by GitBox <gi...@apache.org>.
sandynz commented on code in PR #19979:
URL: https://github.com/apache/shardingsphere/pull/19979#discussion_r940165150
##########
shardingsphere-kernel/shardingsphere-data-pipeline/shardingsphere-data-pipeline-core/src/main/java/org/apache/shardingsphere/data/pipeline/core/api/GovernanceRepositoryAPI.java:
##########
@@ -41,9 +40,11 @@ public interface GovernanceRepositoryAPI {
/**
* Persist job progress.
*
- * @param jobContext job context
+ * @param jobId job id
+ * @param shardingItem sharding item
+ * @param progressValue progress value
*/
- void persistJobProgress(PipelineJobContext jobContext);
+ void persistJobProgress(String jobId, int shardingItem, String progressValue);
/**
* Get job progress.
Review Comment:
It's better to refactor `JobProgress getJobProgress(String jobId, int shardingItem);` too
##########
shardingsphere-test/shardingsphere-pipeline-test/src/test/java/org/apache/shardingsphere/data/pipeline/api/impl/GovernanceRepositoryAPIImplTest.java:
##########
@@ -65,16 +67,19 @@ public final class GovernanceRepositoryAPIImplTest {
private static GovernanceRepositoryAPI governanceRepositoryAPI;
+ private static RuleAlteredJobAPI ruleAlteredJobAPI;
+
Review Comment:
It's better not depend on RuleAlteredJobAPI, since RuleAlteredJobAPIImpl depend on GovernanceRepositoryAPI
##########
shardingsphere-test/shardingsphere-pipeline-test/src/test/resources/META-INF/services/org.apache.shardingsphere.data.pipeline.api.RuleAlteredJobAPI:
##########
@@ -0,0 +1,18 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements. See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+org.apache.shardingsphere.data.pipeline.core.api.impl.RuleAlteredJobAPIImpl
Review Comment:
Is it required to configure RuleAlteredJobAPIImpl?
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] codecov-commenter commented on pull request #19979: Refactor GovernanceRepositoryAPI for common usage
Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on PR #19979:
URL: https://github.com/apache/shardingsphere/pull/19979#issuecomment-1208074761
# [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/19979?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
> Merging [#19979](https://codecov.io/gh/apache/shardingsphere/pull/19979?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (d258d7b) into [master](https://codecov.io/gh/apache/shardingsphere/commit/83473dcd4e53b52ff18368da47e5b71b423df81d?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (83473dc) will **increase** coverage by `0.00%`.
> The diff coverage is `29.46%`.
```diff
@@ Coverage Diff @@
## master #19979 +/- ##
=========================================
Coverage 60.25% 60.25%
Complexity 2412 2412
=========================================
Files 3859 3862 +3
Lines 54715 54769 +54
Branches 7660 7669 +9
=========================================
+ Hits 32966 32999 +33
- Misses 18915 18936 +21
Partials 2834 2834
```
| [Impacted Files](https://codecov.io/gh/apache/shardingsphere/pull/19979?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
|---|---|---|
| [...ata/type/c3p0/C3P0DataSourcePoolFieldMetaData.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUtaW5mcmEvc2hhcmRpbmdzcGhlcmUtaW5mcmEtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9pbmZyYS9kYXRhc291cmNlL3Bvb2wvbWV0YWRhdGEvdHlwZS9jM3AwL0MzUDBEYXRhU291cmNlUG9vbEZpZWxkTWV0YURhdGEuamF2YQ==) | `0.00% <0.00%> (ø)` | |
| [...ine/core/api/impl/GovernanceRepositoryAPIImpl.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL2NvcmUvYXBpL2ltcGwvR292ZXJuYW5jZVJlcG9zaXRvcnlBUElJbXBsLmphdmE=) | `0.00% <0.00%> (ø)` | |
| [.../pipeline/core/api/impl/RuleAlteredJobAPIImpl.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL2NvcmUvYXBpL2ltcGwvUnVsZUFsdGVyZWRKb2JBUElJbXBsLmphdmE=) | `0.00% <0.00%> (ø)` | |
| [...ess/persist/PipelineJobProgressPersistService.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL2NvcmUvam9iL3Byb2dyZXNzL3BlcnNpc3QvUGlwZWxpbmVKb2JQcm9ncmVzc1BlcnNpc3RTZXJ2aWNlLmphdmE=) | `0.00% <0.00%> (ø)` | |
| [...peline/core/job/progress/yaml/YamlJobProgress.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL2NvcmUvam9iL3Byb2dyZXNzL3lhbWwvWWFtbEpvYlByb2dyZXNzLmphdmE=) | `0.00% <0.00%> (ø)` | |
| [...core/job/progress/yaml/YamlJobProgressSwapper.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL2NvcmUvam9iL3Byb2dyZXNzL3lhbWwvWWFtbEpvYlByb2dyZXNzU3dhcHBlci5qYXZh) | `0.00% <0.00%> (ø)` | |
| [...line/scenario/rulealtered/AbstractPipelineJob.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL3NjZW5hcmlvL3J1bGVhbHRlcmVkL0Fic3RyYWN0UGlwZWxpbmVKb2IuamF2YQ==) | `0.00% <0.00%> (ø)` | |
| [.../pipeline/scenario/rulealtered/RuleAlteredJob.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL3NjZW5hcmlvL3J1bGVhbHRlcmVkL1J1bGVBbHRlcmVkSm9iLmphdmE=) | `0.00% <0.00%> (ø)` | |
| [...ne/scenario/rulealtered/RuleAlteredJobContext.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL3NjZW5hcmlvL3J1bGVhbHRlcmVkL1J1bGVBbHRlcmVkSm9iQ29udGV4dC5qYXZh) | `0.00% <0.00%> (ø)` | |
| [.../scenario/rulealtered/RuleAlteredJobScheduler.java](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c2hhcmRpbmdzcGhlcmUta2VybmVsL3NoYXJkaW5nc3BoZXJlLWRhdGEtcGlwZWxpbmUvc2hhcmRpbmdzcGhlcmUtZGF0YS1waXBlbGluZS1jb3JlL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zaGFyZGluZ3NwaGVyZS9kYXRhL3BpcGVsaW5lL3NjZW5hcmlvL3J1bGVhbHRlcmVkL1J1bGVBbHRlcmVkSm9iU2NoZWR1bGVyLmphdmE=) | `0.00% <0.00%> (ø)` | |
| ... and [28 more](https://codecov.io/gh/apache/shardingsphere/pull/19979/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
:mega: Codecov can now indicate which changes are the most critical in Pull Requests. [Learn more](https://about.codecov.io/product/feature/runtime-insights/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
--
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: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org