Skip to content
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

fix: Missing support for headers + NPE/clean-up [DHIS2-16065] #15865

Merged
merged 11 commits into from
Dec 11, 2023

Conversation

maikelarabori
Copy link
Contributor

This PR adds support for "headers" param, fixes a NPE and also fixes an exception handling that was not working correctly.

I noticed that exactly the same items and columns were used across many places. I grouped them into an Enum.

@maikelarabori maikelarabori added the run-api-analytics-tests Enables analytics e2e tests label Dec 8, 2023
Copy link

codecov bot commented Dec 8, 2023

Codecov Report

Merging #15865 (326299c) into master (db8a664) will increase coverage by 0.01%.
Report is 3 commits behind head on master.
The diff coverage is 70.37%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master   #15865      +/-   ##
============================================
+ Coverage     66.37%   66.38%   +0.01%     
- Complexity    31435    31441       +6     
============================================
  Files          3487     3489       +2     
  Lines        130030   130128      +98     
  Branches      15183    15186       +3     
============================================
+ Hits          86307    86390      +83     
- Misses        36646    36663      +17     
+ Partials       7077     7075       -2     
Flag Coverage Δ
integration 50.08% <68.25%> (+0.02%) ⬆️
integration-h2 32.36% <39.15%> (+0.02%) ⬆️
unit 30.44% <48.14%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
...src/main/java/org/hisp/dhis/period/PeriodType.java 86.44% <ø> (ø)
.../event/data/DefaultEnrollmentAnalyticsService.java 80.00% <100.00%> (+5.00%) ⬆️
...ytics/event/data/DefaultEventDataQueryService.java 83.33% <100.00%> (+0.06%) ⬆️
...nalytics/event/data/JdbcEventAnalyticsManager.java 66.07% <100.00%> (+0.12%) ⬆️
...his/analytics/table/JdbcAnalyticsTableManager.java 68.58% <100.00%> (-0.55%) ⬇️
...a/org/hisp/dhis/analytics/common/ColumnHeader.java 100.00% <100.00%> (ø)
...rdetection/parser/OutlierDetectionQueryParser.java 85.71% <100.00%> (ø)
...p/dhis/outlierdetection/OutlierDetectionQuery.java 0.00% <0.00%> (ø)
...rocessor/AnalyticsZScoreSqlStatementProcessor.java 73.07% <75.00%> (ø)
...ction/service/AbstractOutlierDetectionManager.java 96.96% <75.00%> (ø)
... and 5 more

... and 13 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a0a14f9...326299c. Read the comment docs.

Copy link
Contributor

@gnespolino gnespolino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good one 👍

@maikelarabori maikelarabori enabled auto-merge (squash) December 11, 2023 13:42
Copy link

sonarcloud bot commented Dec 11, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@maikelarabori maikelarabori merged commit 1390944 into master Dec 11, 2023
13 checks passed
@maikelarabori maikelarabori deleted the DHIS2-16065_2.41 branch December 11, 2023 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
run-api-analytics-tests Enables analytics e2e tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants