You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hugegraph.apache.org by GitBox <gi...@apache.org> on 2022/04/27 13:32:39 UTC

[GitHub] [incubator-hugegraph] seagle-yuan opened a new pull request, #1854: fix checkstyle of core-task issue

seagle-yuan opened a new pull request, #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854

   fix checkstyel issue
   
   com.baidu.hugegraph.HugeFactory.java
   com.baidu.hugegraph.HugeGraph.java
   com.baidu.hugegraph.HugeGraphParams.java
   com.baidu.hugegraph.StandardHugeGraph.java
   com.baidu.hugegraph.io.HugeGraphSONModule.java
   com.baidu.hugegraph.job.computer.AbstractComputer.java
   com.baidu.hugegraph.job.computer.LouvainComputer.java
   com.baidu.hugegraph.job.system.DeleteExpiredIndexJob.java 
   com.baidu.hugegraph.plugin.HugeGraphGremlinPlugin.java
   com.baidu.hugegraph.schema.builder.PropertyKeyBuilder.java
   com.baidu.hugegraph.security.HugeSecurityManager.java
   com.baidu.hugegraph.task.HugeTask.java
   com.baidu.hugegraph.task.TaskManager.java
   com.baidu.hugegraph.task.TaskScheduler.java


-- 
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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-hugegraph] javeme commented on a diff in pull request #1854: fix checkstyle of core-task issue

Posted by GitBox <gi...@apache.org>.
javeme commented on code in PR #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854#discussion_r864429335


##########
hugegraph-core/src/main/java/com/baidu/hugegraph/job/computer/AbstractComputer.java:
##########
@@ -117,7 +114,7 @@ public Object call(Job<Object> job, Map<String, Object> parameters) {
             Process process = builder.start();
 
             StringBuilder output = new StringBuilder();
-            try(LineNumberReader reader = new LineNumberReader(
+            try (LineNumberReader reader = new LineNumberReader(

Review Comment:
   also update alignment of line 118



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/schema/builder/PropertyKeyBuilder.java:
##########
@@ -69,8 +69,8 @@ public PropertyKeyBuilder(SchemaTransaction transaction,
         this.checkExist = true;
     }
 
-    public PropertyKeyBuilder(SchemaTransaction transaction,
-                              HugeGraph graph, PropertyKey copy) {
+    public PropertyKeyBuilder(SchemaTransaction transaction, HugeGraph graph,

Review Comment:
   prefer to keep old style (don't exceed guide line length 80 chars)



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/schema/builder/PropertyKeyBuilder.java:
##########
@@ -44,7 +44,7 @@
 import com.baidu.hugegraph.util.E;
 
 public class PropertyKeyBuilder extends AbstractBuilder
-                                implements PropertyKey.Builder {
+        implements PropertyKey.Builder {

Review Comment:
   prefer to keep old style 



-- 
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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-hugegraph] javeme commented on a diff in pull request #1854: fix checkstyle of core-task issue

Posted by GitBox <gi...@apache.org>.
javeme commented on code in PR #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854#discussion_r859819260


##########
hugegraph-core/src/main/java/com/baidu/hugegraph/job/computer/AbstractComputer.java:
##########
@@ -117,7 +114,7 @@ public Object call(Job<Object> job, Map<String, Object> parameters) {
             Process process = builder.start();
 
             StringBuilder output = new StringBuilder();
-            try(LineNumberReader reader = new LineNumberReader(
+            try (LineNumberReader reader = new LineNumberReader(

Review Comment:
   also update alignment?



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/security/HugeSecurityManager.java:
##########
@@ -47,10 +47,10 @@ public class HugeSecurityManager extends SecurityManager {
             "org.apache.tinkerpop.gremlin.groovy.jsr223.GremlinGroovyScriptEngine"
     );
 
-    private static final Set<String> DENIED_PERMISSIONS = ImmutableSet.of(
-            "setSecurityManager"
-            //"suppressAccessChecks"
-    );
+    //"suppressAccessChecks"

Review Comment:
   expect to add a space after "//"



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/security/HugeSecurityManager.java:
##########
@@ -47,10 +47,10 @@ public class HugeSecurityManager extends SecurityManager {
             "org.apache.tinkerpop.gremlin.groovy.jsr223.GremlinGroovyScriptEngine"
     );
 
-    private static final Set<String> DENIED_PERMISSIONS = ImmutableSet.of(
-            "setSecurityManager"
-            //"suppressAccessChecks"
-    );
+    //"suppressAccessChecks"

Review Comment:
   `// TODO: add "suppressAccessChecks"`



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/schema/builder/PropertyKeyBuilder.java:
##########
@@ -69,8 +68,7 @@ public PropertyKeyBuilder(SchemaTransaction transaction,
         this.checkExist = true;
     }
 
-    public PropertyKeyBuilder(SchemaTransaction transaction,
-                              HugeGraph graph, PropertyKey copy) {
+    public PropertyKeyBuilder(SchemaTransaction transaction, HugeGraph graph, PropertyKey copy) {

Review Comment:
   ditto



##########
hugegraph-core/src/main/java/com/baidu/hugegraph/schema/builder/PropertyKeyBuilder.java:
##########
@@ -43,8 +43,7 @@
 import com.baidu.hugegraph.type.define.WriteType;
 import com.baidu.hugegraph.util.E;
 
-public class PropertyKeyBuilder extends AbstractBuilder
-                                implements PropertyKey.Builder {
+public class PropertyKeyBuilder extends AbstractBuilder implements PropertyKey.Builder {

Review Comment:
   can we keep 80 chars as guide line length?



-- 
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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-hugegraph] imbajin merged pull request #1854: fix checkstyle of core-task issue

Posted by GitBox <gi...@apache.org>.
imbajin merged PR #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854


-- 
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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-hugegraph] codecov[bot] commented on pull request #1854: fix checkstyle of core-task issue

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on PR #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854#issuecomment-1111026095

   # [Codecov](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?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 [#1854](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (6040d56) into [master](https://codecov.io/gh/apache/incubator-hugegraph/commit/0ed2e3b80789620d3e0da43216747502c7d3e729?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (0ed2e3b) will **decrease** coverage by `19.88%`.
   > The diff coverage is `78.12%`.
   
   ```diff
   @@              Coverage Diff              @@
   ##             master    #1854       +/-   ##
   =============================================
   - Coverage     70.70%   50.81%   -19.89%     
   + Complexity      980      659      -321     
   =============================================
     Files           447      447               
     Lines         38041    38038        -3     
     Branches       5389     5376       -13     
   =============================================
   - Hits          26897    19330     -7567     
   - Misses         8508    16601     +8093     
   + Partials       2636     2107      -529     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...e/src/main/java/com/baidu/hugegraph/HugeGraph.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL0h1Z2VHcmFwaC5qYXZh) | `65.30% <ø> (ø)` | |
   | [...in/java/com/baidu/hugegraph/StandardHugeGraph.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL1N0YW5kYXJkSHVnZUdyYXBoLmphdmE=) | `62.74% <ø> (-4.22%)` | :arrow_down: |
   | [...baidu/hugegraph/job/computer/AbstractComputer.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL2pvYi9jb21wdXRlci9BYnN0cmFjdENvbXB1dGVyLmphdmE=) | `0.00% <0.00%> (ø)` | |
   | [.../baidu/hugegraph/job/computer/LouvainComputer.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL2pvYi9jb21wdXRlci9Mb3V2YWluQ29tcHV0ZXIuamF2YQ==) | `0.00% <ø> (ø)` | |
   | [.../baidu/hugegraph/security/HugeSecurityManager.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL3NlY3VyaXR5L0h1Z2VTZWN1cml0eU1hbmFnZXIuamF2YQ==) | `0.00% <0.00%> (-76.89%)` | :arrow_down: |
   | [...src/main/java/com/baidu/hugegraph/HugeFactory.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL0h1Z2VGYWN0b3J5LmphdmE=) | `65.07% <80.00%> (-14.29%)` | :arrow_down: |
   | [...ava/com/baidu/hugegraph/io/HugeGraphSONModule.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL2lvL0h1Z2VHcmFwaFNPTk1vZHVsZS5qYXZh) | `81.98% <100.00%> (-0.91%)` | :arrow_down: |
   | [...du/hugegraph/job/system/DeleteExpiredIndexJob.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL2pvYi9zeXN0ZW0vRGVsZXRlRXhwaXJlZEluZGV4Sm9iLmphdmE=) | `85.71% <100.00%> (ø)` | |
   | [...baidu/hugegraph/plugin/HugeGraphGremlinPlugin.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL3BsdWdpbi9IdWdlR3JhcGhHcmVtbGluUGx1Z2luLmphdmE=) | `86.66% <100.00%> (ø)` | |
   | [...u/hugegraph/schema/builder/PropertyKeyBuilder.java](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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-aHVnZWdyYXBoLWNvcmUvc3JjL21haW4vamF2YS9jb20vYmFpZHUvaHVnZWdyYXBoL3NjaGVtYS9idWlsZGVyL1Byb3BlcnR5S2V5QnVpbGRlci5qYXZh) | `83.42% <100.00%> (-6.29%)` | :arrow_down: |
   | ... and [191 more](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854/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) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [0ed2e3b...6040d56](https://codecov.io/gh/apache/incubator-hugegraph/pull/1854?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-hugegraph] seagle-yuan commented on a diff in pull request #1854: fix checkstyle of core-task issue

Posted by GitBox <gi...@apache.org>.
seagle-yuan commented on code in PR #1854:
URL: https://github.com/apache/incubator-hugegraph/pull/1854#discussion_r863577980


##########
hugegraph-core/src/main/java/com/baidu/hugegraph/job/computer/AbstractComputer.java:
##########
@@ -117,7 +114,7 @@ public Object call(Job<Object> job, Map<String, Object> parameters) {
             Process process = builder.start();
 
             StringBuilder output = new StringBuilder();
-            try(LineNumberReader reader = new LineNumberReader(
+            try (LineNumberReader reader = new LineNumberReader(

Review Comment:
   add whitespace after "try" word



-- 
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: dev-unsubscribe@hugegraph.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org