@diosmosis opened this Pull Request on July 27th 2021 Member


Currently when aggregating reports over multi periods, we get the blob data for every child period, inflate the blob data for every period into a DataTable tree, then add them together. Afterwards we clean up the extra DataTables, but in the meantime a lot of memory is used, especially when the reports are large. This PR switches to inflating the DataTable tree for just one period at a time and should use less memory overall.


  • [ ] Functional review done
  • [ ] Potential edge cases thought about (behavior of the code with strange input, with strange internal state or possible interactions with other Matomo subsystems)
  • [ ] Usability review done (is anything maybe unclear or think about anything that would cause people to reach out to support)
  • [ ] Security review done see checklist
  • [ ] Code review done
  • [ ] Tests were added if useful/possible
  • [ ] Reviewed for breaking changes
  • [ ] Developer changelog updated if needed
  • [ ] Documentation added if needed
  • [ ] Existing documentation updated if needed
@diosmosis commented on August 11th 2021 Member

Transitions screenshot change is not correct, but it is due to an unrelated bug: https://github.com/matomo-org/matomo/issues/17875

@diosmosis commented on August 18th 2021 Member

@sgiehl removed the debugging code and fixed some tests

@tsteur commented on August 19th 2021 Member

Looks good to me @diosmosis 👍 Great, this will reduce memory quite a bit 💯

This Pull Request was closed on August 19th 2021
Powered by GitHub Issue Mirror