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: sort analytics request params and items for cache hit optimization (DHIS2-17861) #1695

Merged
merged 4 commits into from
Aug 8, 2024

Conversation

janhenrikoverland
Copy link
Collaborator

@janhenrikoverland janhenrikoverland commented Aug 8, 2024

Implements DHIS2-17861

Moves the sorting logic to the data and metadata queries. Makes generateDimensionStrings pure.

  • Unit tests
  • Manual tests
  • Documentation not needed

Before

Request Param name Param value Param sorting Item sorting
Data Dimension dx:fbfJHSPpUQD;cYeuwXTCPkU,pe:THIS_MONTH;LAST_12_MONTHS,ou:lc3eMKXaEfw;jUb8gELQApl X X
Data Filter pe:THIS_MONTH;LAST_12_MONTHS
ou:lc3eMKXaEfw;jUb8gELQApl
X X
Metadata Dimension dx:fbfJHSPpUQD;cYeuwXTCPkU,pe:THIS_MONTH;LAST_12_MONTHS,ou:lc3eMKXaEfw;jUb8gELQApl X OK
Metadata Filter pe:THIS_MONTH;LAST_12_MONTHS
ou:lc3eMKXaEfw;jUb8gELQApl
X OK

After

Request Param name Param value Param sorting Item sorting
Data Dimension dx:cYeuwXTCPkU;fbfJHSPpUQD,ou:jUb8gELQApl;lc3eMKXaEfw,pe:LAST_12_MONTHS;THIS_MONTH OK OK
Data Filter ou:jUb8gELQApl;lc3eMKXaEfw
pe:LAST_12_MONTHS;THIS_MONTH
OK OK
Metadata Dimension dx:fbfJHSPpUQD;cYeuwXTCPkU,ou:lc3eMKXaEfw;jUb8gELQApl,pe:THIS_MONTH;LAST_12_MONTHS OK OK
Metadata Filter ou:lc3eMKXaEfw;jUb8gELQApl
pe:THIS_MONTH;LAST_12_MONTHS
OK OK

@janhenrikoverland janhenrikoverland changed the title fix: sort analytics request params and items for cache hit optimization fix: sort analytics request params and items for cache hit optimization (DHIS2-17861) Aug 8, 2024
@janhenrikoverland janhenrikoverland merged commit 80c9306 into master Aug 8, 2024
10 checks passed
@janhenrikoverland janhenrikoverland deleted the fix/sort-request-params-items branch August 8, 2024 10:44
dhis2-bot added a commit that referenced this pull request Aug 8, 2024
## [26.8.1](v26.8.0...v26.8.1) (2024-08-08)

### Bug Fixes

* sort analytics request params and items for cache hit optimization (DHIS2-17861) ([#1695](#1695)) ([80c9306](80c9306))
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 26.8.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants