You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "Cpaulyz (via GitHub)" <gi...@apache.org> on 2025/06/01 17:47:59 UTC
[PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Cpaulyz opened a new pull request, #15628:
URL: https://github.com/apache/iotdb/pull/15628
## Description
Add new parameter [ignoreNull] and supported data type for VARIATION Function
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2929663655
## [](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628) **Quality Gate passed**
Issues
 [8 New issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628)
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2967306054
## [Codecov](https://app.codecov.io/gh/apache/iotdb/pull/15628?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
Attention: Patch coverage is `0%` with `63 lines` in your changes missing coverage. Please review.
> Project coverage is 39.11%. Comparing base [(`8fb0b46`)](https://app.codecov.io/gh/apache/iotdb/commit/8fb0b4688242546b6c8238d5d14314dd383d5708?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) to head [(`5f203b7`)](https://app.codecov.io/gh/apache/iotdb/commit/5f203b7711af2b0a51755251cb1560f085d571d5?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
> Report is 48 commits behind head on master.
| [Files with missing lines](https://app.codecov.io/gh/apache/iotdb/pull/15628?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [...builtin/relational/tvf/VariationTableFunction.java](https://app.codecov.io/gh/apache/iotdb/pull/15628?src=pr&el=tree&filepath=iotdb-core%2Fnode-commons%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fiotdb%2Fcommons%2Fudf%2Fbuiltin%2Frelational%2Ftvf%2FVariationTableFunction.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-aW90ZGItY29yZS9ub2RlLWNvbW1vbnMvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2lvdGRiL2NvbW1vbnMvdWRmL2J1aWx0aW4vcmVsYXRpb25hbC90dmYvVmFyaWF0aW9uVGFibGVGdW5jdGlvbi5qYXZh) | 0.00% | [61 Missing :warning: ](https://app.codecov.io/gh/apache/iotdb/pull/15628?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...ons/udf/builtin/relational/tvf/WindowTVFUtils.java](https://app.codecov.io/gh/apache/iotdb/pull/15628?src=pr&el=tree&filepath=iotdb-core%2Fnode-commons%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fiotdb%2Fcommons%2Fudf%2Fbuiltin%2Frelational%2Ftvf%2FWindowTVFUtils.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-aW90ZGItY29yZS9ub2RlLWNvbW1vbnMvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2lvdGRiL2NvbW1vbnMvdWRmL2J1aWx0aW4vcmVsYXRpb25hbC90dmYvV2luZG93VFZGVXRpbHMuamF2YQ==) | 0.00% | [2 Missing :warning: ](https://app.codecov.io/gh/apache/iotdb/pull/15628?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## master #15628 +/- ##
============================================
- Coverage 39.14% 39.11% -0.03%
Complexity 198 198
============================================
Files 4821 4834 +13
Lines 311671 314230 +2559
Branches 39045 39412 +367
============================================
+ Hits 121992 122916 +924
- Misses 189679 191314 +1635
```
</details>
[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/iotdb/pull/15628?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2989495122
## [](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628) **Quality Gate passed**
Issues
 [8 New issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628)
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2986814142
## [](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628) **Quality Gate passed**
Issues
 [10 New issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628)
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2927624817
## [](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628) **Quality Gate passed**
Issues
 [4 New issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628)
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "JackieTien97 (via GitHub)" <gi...@apache.org>.
JackieTien97 commented on code in PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#discussion_r2127846370
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/udf/builtin/relational/tvf/VariationTableFunction.java:
##########
@@ -62,6 +67,13 @@ public List<ParameterSpecification> getArgumentsSpecifications() {
ScalarParameterSpecification.builder()
.name(DELTA_PARAMETER_NAME)
.type(Type.DOUBLE)
+ .defaultValue(0.0)
+ .addChecker(NON_NEGATIVE_DOUBLE_CHECKER)
+ .build(),
+ ScalarParameterSpecification.builder()
+ .name(IGNORE_NULL_PARAMETER_NAME)
+ .type(Type.BOOLEAN)
+ .defaultValue(false)
Review Comment:
```suggestion
.defaultValue(true)
```
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/udf/builtin/relational/tvf/VariationTableFunction.java:
##########
@@ -147,13 +234,20 @@ public void finish(
outputWindow(properColumnBuilders, passThroughIndexBuilder);
}
- private void outputWindow(
+ protected void outputWindow(
List<ColumnBuilder> properColumnBuilders, ColumnBuilder passThroughIndexBuilder) {
+ boolean increaseIndex = false;
for (long i = currentStartIndex; i < curIndex; i++) {
+ if (!skipIndex.isEmpty() && i == skipIndex.peek()) {
+ // skip the index if it is in the skip queue
+ skipIndex.poll();
+ continue;
+ }
Review Comment:
we should also output those null line., like 1, null, 1, null, 2, null, 2, 3, null, 3, null,
first group contains 1, null, 1, null
secodn group contains 2, null, 2,
third group contains 3, null, 3, null
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "JackieTien97 (via GitHub)" <gi...@apache.org>.
JackieTien97 commented on code in PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#discussion_r2127848572
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/udf/builtin/relational/tvf/VariationTableFunction.java:
##########
@@ -147,13 +234,20 @@ public void finish(
outputWindow(properColumnBuilders, passThroughIndexBuilder);
}
- private void outputWindow(
+ protected void outputWindow(
List<ColumnBuilder> properColumnBuilders, ColumnBuilder passThroughIndexBuilder) {
+ boolean increaseIndex = false;
for (long i = currentStartIndex; i < curIndex; i++) {
+ if (!skipIndex.isEmpty() && i == skipIndex.peek()) {
+ // skip the index if it is in the skip queue
+ skipIndex.poll();
+ continue;
+ }
Review Comment:
we should also output those null line., like 1, null, null, 1, null, 2, null, 2, 3, null, 3, null,
if ignore_null => true:
first group contains 1, null, null, 1, null
secodn group contains 2, null, 2,
third group contains 3, null, 3, null
if ignore_null => false:
first group contains 1
second group contains null, null
third group contains 1
forth group contains null
fifth group contains 2
sixth group contains null
seventh group contains 2
eighth group contains 3
ninth group contains null
tenth group contains 3
eleventh group contains null
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "sonarqubecloud[bot] (via GitHub)" <gi...@apache.org>.
sonarqubecloud[bot] commented on PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#issuecomment-2967095402
## [](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628) **Quality Gate passed**
Issues
 [8 New issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0 Accepted issues](https://sonarcloud.io/project/issues?id=apache_iotdb&pullRequest=15628&issueStatuses=ACCEPTED)
Measures
 [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_iotdb&pullRequest=15628&issueStatuses=OPEN,CONFIRMED&sinceLeakPeriod=true)
 [0.0% Coverage on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_coverage&view=list)
 [0.0% Duplication on New Code](https://sonarcloud.io/component_measures?id=apache_iotdb&pullRequest=15628&metric=new_duplicated_lines_density&view=list)
[See analysis details on SonarQube Cloud](https://sonarcloud.io/dashboard?id=apache_iotdb&pullRequest=15628)
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "Cpaulyz (via GitHub)" <gi...@apache.org>.
Cpaulyz commented on code in PR #15628:
URL: https://github.com/apache/iotdb/pull/15628#discussion_r2142920903
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/udf/builtin/relational/tvf/VariationTableFunction.java:
##########
@@ -62,6 +67,13 @@ public List<ParameterSpecification> getArgumentsSpecifications() {
ScalarParameterSpecification.builder()
.name(DELTA_PARAMETER_NAME)
.type(Type.DOUBLE)
+ .defaultValue(0.0)
+ .addChecker(NON_NEGATIVE_DOUBLE_CHECKER)
+ .build(),
+ ScalarParameterSpecification.builder()
+ .name(IGNORE_NULL_PARAMETER_NAME)
+ .type(Type.BOOLEAN)
+ .defaultValue(false)
Review Comment:
done
##########
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/udf/builtin/relational/tvf/VariationTableFunction.java:
##########
@@ -147,13 +234,20 @@ public void finish(
outputWindow(properColumnBuilders, passThroughIndexBuilder);
}
- private void outputWindow(
+ protected void outputWindow(
List<ColumnBuilder> properColumnBuilders, ColumnBuilder passThroughIndexBuilder) {
+ boolean increaseIndex = false;
for (long i = currentStartIndex; i < curIndex; i++) {
+ if (!skipIndex.isEmpty() && i == skipIndex.peek()) {
+ // skip the index if it is in the skip queue
+ skipIndex.poll();
+ continue;
+ }
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Add new parameter [ignoreNull] and supported data type for VARIATION Function [iotdb]
Posted by "JackieTien97 (via GitHub)" <gi...@apache.org>.
JackieTien97 merged PR #15628:
URL: https://github.com/apache/iotdb/pull/15628
--
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-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org