We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ae3fc46 commit 55bcf4cCopy full SHA for 55bcf4c
src/jdk.jfr/share/classes/jdk/jfr/internal/query/Function.java
@@ -89,7 +89,7 @@ public static Function create(Field field) {
89
return createPercentile(field, 0.99);
90
}
91
if (aggregator == Aggregator.P999) {
92
- return createPercentile(field, 0.9999);
+ return createPercentile(field, 0.999);
93
94
if (aggregator == Aggregator.MAXIMUM) {
95
return new Maximum();
@@ -578,7 +578,7 @@ public Object result() {
578
double doubleIndex = (size + 1) * percentile;
579
int valueIndex = (int) doubleIndex - 1;
580
int valueNextIndex = (int) doubleIndex;
581
- double fraction = doubleIndex - valueIndex;
+ double fraction = doubleIndex - (int) doubleIndex;
582
583
if (valueIndex < 0) {
584
return numbers.getFirst();
0 commit comments