-
-
Notifications
You must be signed in to change notification settings - Fork 83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Aqa metrics/#5121 #972
base: master
Are you sure you want to change the base?
Aqa metrics/#5121 #972
Conversation
✅ Deploy Preview for eclipsefdn-adoptium-trss canceled.
|
Signed-off-by: yelias <[email protected]> Signed-off-by: YosiElias <[email protected]>
… rerun Signed-off-by: yelias <[email protected]> Signed-off-by: YosiElias <[email protected]>
Signed-off-by: yelias <[email protected]> Signed-off-by: YosiElias <[email protected]>
Signed-off-by: yelias <[email protected]> Signed-off-by: YosiElias <[email protected]>
Signed-off-by: yelias <[email protected]> Signed-off-by: YosiElias <[email protected]>
Signed-off-by: YosiElias <[email protected]>
…hst failed tests.
ce6b530
to
c62fd85
Compare
Thanks @YosiElias, we also need Liav to sign the ECA (as you had to recently, details at https://adoptium.net/docs/eca-sign-off/). |
c62fd85
to
2817e16
Compare
2817e16
to
c62fd85
Compare
Signed-off-by: YosiElias <[email protected]>
c62fd85
to
aa52396
Compare
This PR will impact the performance of the Grid View page as it contains large/inefficient MongoDB queries. Since we are already investigating existing performance issues, adding this change could further complicate the situation. From a user’s perspective, |
getSpecificAggregation(type, buildNameRegex, query) { | ||
switch (type) { | ||
case 'totals': | ||
return this.getTotalsAggregation(query, buildNameRegex); | ||
case 'rerunDetails': | ||
return this.getRerunDetailsAggregation(); | ||
case 'jobsDetails': | ||
return this.getJobsDetailsAggregation(); | ||
default: | ||
throw new Error(`Unknown type: ${type}`); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
getSpecificAggregation() calls different functions based on the switch type. Each function has its own mandate and purpose. I do not think we should create getSpecificAggregation() and use the switch case here.
If you really want to utilize the common code in testResultsBaseAggregation(), pass specificAggregation in testResultsBaseAggregation().
getJobsDetailsAggregation() { | ||
return [ | ||
{ | ||
$addFields: { | ||
job_success_rate: { | ||
$round: [ | ||
{ | ||
$multiply: [ | ||
{ | ||
$divide: [ | ||
{ | ||
$size: { | ||
$filter: { | ||
input: "$childBuilds", | ||
as: "build", | ||
cond: { $eq: ["$$build.buildResult", "SUCCESS"] } | ||
} | ||
} | ||
}, | ||
{ $size: "$childBuilds" } | ||
] | ||
}, | ||
100 | ||
] | ||
}, | ||
2 | ||
] | ||
} | ||
} | ||
}, | ||
{ $unset: ['childBuilds'] } | ||
]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you do calculations in JS, your code should be much simpler.
as: 'build', | ||
cond: { | ||
$and: [ | ||
{ $in: ['$$build.buildResult', ['UNSTABLE', 'FAILED', 'ABORTED']] }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not think there is FAILED
state in buildResult. It should be FAILURE
.
}, | ||
{ $unset: ['childBuilds', 'manual_rerun_needed_list'] } | ||
]; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is complex to review and test. Could you write a pipeline query?
Key Performance Improvements
- Avoids multiple $filter operations by pre-filtering failed builds.
- Replaces $reduce with $sum in $lookup, making it more efficient.
- Minimizes $regexMatch usage, reducing processing time.
- Efficient regex generation using $group, avoiding multiple conditionals.
Here are some ways to break this down:
|
Fixes: #5121
Added:
Moved 'Tests Success Rate' to be under 'Test Summary'
Test Results Table:

When clicking on the 'Manual Rerun Needed' link:
