Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2024-01-04 Thread via GitHub


OneSizeFitsQuorum merged PR #11857:
URL: https://github.com/apache/iotdb/pull/11857


-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2024-01-04 Thread via GitHub


codecov-commenter commented on PR #11857:
URL: https://github.com/apache/iotdb/pull/11857#issuecomment-1878127344

   ## 
[Codecov](https://app.codecov.io/gh/apache/iotdb/pull/11857?src=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   All modified and coverable lines are covered by tests :white_check_mark:
   > Comparison is base 
[(`20bdc07`)](https://app.codecov.io/gh/apache/iotdb/commit/20bdc070098479fdaadce29dc7a1435f56ab?el=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 48.97% compared to head 
[(`a593e00`)](https://app.codecov.io/gh/apache/iotdb/pull/11857?src=pr=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 48.93%.
   
   
   Additional details and impacted files
   
   
   ```diff
   @@ Coverage Diff  @@
   ## master   #11857  +/-   ##
   
   - Coverage 48.97%   48.93%   -0.05% 
   + Complexity2559425566  -28 
   
 Files  2908 2908  
 Lines181274   181276   +2 
 Branches  2169121691  
   
   - Hits  8877688703  -73 
   - Misses9249892573  +75 
   ```
   
   
   
   
   
   [:umbrella: View full report in Codecov by 
Sentry](https://app.codecov.io/gh/apache/iotdb/pull/11857?src=pr=continue_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   
   :loudspeaker: Have feedback on the report? [Share it 
here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   


-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2024-01-04 Thread via GitHub


sonarcloud[bot] commented on PR #11857:
URL: https://github.com/apache/iotdb/pull/11857#issuecomment-1878104363

   ## [![Quality Gate 
Passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/qg-passed-20px.png
 'Quality Gate 
Passed')](https://sonarcloud.io/dashboard?id=apache_iotdb=11857) 
**Quality Gate passed**  
   Kudos, no new issues were introduced!
   
   [0 New 
issues](https://sonarcloud.io/project/issues?id=apache_iotdb=11857=false=true)
  
   [0 Security 
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb=11857=false=true)
  
   [0.0% Coverage on New 
Code](https://sonarcloud.io/component_measures?id=apache_iotdb=11857=new_coverage=list)
  
   [0.0% Duplication on New 
Code](https://sonarcloud.io/component_measures?id=apache_iotdb=11857=new_duplicated_lines_density=list)
  
 
   [See analysis details on 
SonarCloud](https://sonarcloud.io/dashboard?id=apache_iotdb=11857)
   
   


-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2024-01-03 Thread via GitHub


OneSizeFitsQuorum merged PR #11798:
URL: https://github.com/apache/iotdb/pull/11798


-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2024-01-03 Thread via GitHub


BUAAserein commented on PR #11798:
URL: https://github.com/apache/iotdb/pull/11798#issuecomment-1876265547

   
![image](https://github.com/apache/iotdb/assets/65238551/74ce7bfd-739b-4428-b75f-1b62ad0ff2af)
   


-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2023-12-29 Thread via GitHub


BUAAserein commented on code in PR #11798:
URL: https://github.com/apache/iotdb/pull/11798#discussion_r1438081203


##
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/procedure/Procedure.java:
##
@@ -900,4 +895,41 @@ public static boolean haveSameParent(Procedure a, 
Procedure b) {
   public int compareTo(Procedure other) {
 return Long.compare(getProcId(), other.getProcId());
   }
+
+  /**
+   * This function will be called just when procedure is submitted for 
execution.
+   *
+   * @param env The environment passed to the procedure executor
+   */
+  protected void updateMetricsOnSubmit(Env env) {
+ProcedureMetrics metrics = null;
+if (env instanceof ConfigNodeProcedureEnv) {

Review Comment:
   removed



-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2023-12-29 Thread via GitHub


BUAAserein commented on code in PR #11798:
URL: https://github.com/apache/iotdb/pull/11798#discussion_r1438081120


##
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/manager/ConfigManager.java:
##
@@ -248,6 +249,8 @@ public class ConfigManager implements IManager {
 
   private static final String DATABASE = "\tDatabase=";
 
+  private ProcedureMetrics procedureMetrics;

Review Comment:
   fixed



-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2023-12-28 Thread via GitHub


BUAAserein commented on code in PR #11798:
URL: https://github.com/apache/iotdb/pull/11798#discussion_r1438055672


##
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/manager/ConfigManager.java:
##
@@ -248,6 +249,8 @@ public class ConfigManager implements IManager {
 
   private static final String DATABASE = "\tDatabase=";
 
+  private ProcedureMetrics procedureMetrics;

Review Comment:
   Referring to NodeMetrics and PartitionMetrics. Put it in ConfigManager for 
easy access to addMetrics and removeMetrics



-- 
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: reviews-unsubscr...@iotdb.apache.org

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



Re: [PR] [IOTDB-6281] Enhance Procedure metrics [iotdb]

2023-12-28 Thread via GitHub


OneSizeFitsQuorum commented on code in PR #11798:
URL: https://github.com/apache/iotdb/pull/11798#discussion_r1437556713


##
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/manager/ConfigManager.java:
##
@@ -248,6 +249,8 @@ public class ConfigManager implements IManager {
 
   private static final String DATABASE = "\tDatabase=";
 
+  private ProcedureMetrics procedureMetrics;

Review Comment:
   why we put this into ConfigManager rather than ProcedureManager?



##
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/procedure/Procedure.java:
##
@@ -900,4 +895,41 @@ public static boolean haveSameParent(Procedure a, 
Procedure b) {
   public int compareTo(Procedure other) {
 return Long.compare(getProcId(), other.getProcId());
   }
+
+  /**
+   * This function will be called just when procedure is submitted for 
execution.
+   *
+   * @param env The environment passed to the procedure executor
+   */
+  protected void updateMetricsOnSubmit(Env env) {
+ProcedureMetrics metrics = null;
+if (env instanceof ConfigNodeProcedureEnv) {

Review Comment:
   Why we need this judgement?



-- 
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: reviews-unsubscr...@iotdb.apache.org

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