Skip to content

Overhaul stats: Extract events package (part 1) - #1479

Merged
josecelano merged 11 commits into
torrust:developfrom
josecelano:1478-overhaul-stats-extract-events-package
Apr 25, 2025
Merged

josecelano merged 11 commits into
torrust:developfrom
josecelano:1478-overhaul-stats-extract-events-package

Conversation

@josecelano

@josecelano josecelano commented Apr 25, 2025 •

Copy link
Copy Markdown
Member

Overhaul stats: Extract events package.

Subtasks

  • Decouple events from stats in the http core keeper.
  • Decouple events from stats in the udp core keeper.
  • Decouple events from stats in the udp server keeper.
  • Inline function statistics::setup::keeper_factory and statistics::setup::factory. No need for them anymore.
  • Rename all Keeper types to EventBus.
  • Move EventBus to event module.

Implement in part 2 of the PR

  • Create new package events.
  • Create a generic EventBus in the events package and replace concrete versions in packages.

More info in #1480.

@josecelano josecelano self-assigned this Apr 25, 2025
@josecelano josecelano added Code Cleanup / Refactoring Tidying and Making Neat - Developer - Torrust Improvement Experience labels Apr 25, 2025
@josecelano josecelano linked an issue Apr 25, 2025 that may be closed by this pull request
@josecelano
josecelano requested a review from da2ce7 April 25, 2025 15:58
@codecov

codecov Bot commented Apr 25, 2025 •

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 90.00000% with 26 lines in your changes missing coverage. Please review.

Project coverage is 84.36%. Comparing base (4bb7a5a) to head (b0951aa).
Report is 12 commits behind head on develop.

Files with missing lines Patch % Lines
packages/http-tracker-core/src/event/bus.rs 70.00% 6 Missing ⚠️
packages/udp-tracker-core/src/event/bus.rs 70.00% 6 Missing ⚠️
packages/udp-tracker-server/src/event/bus.rs 70.00% 6 Missing ⚠️
.../udp-tracker-core/src/statistics/event/listener.rs 70.00% 2 Missing and 1 partial ⚠️
...dp-tracker-server/src/statistics/event/listener.rs 70.00% 2 Missing and 1 partial ⚠️
...http-tracker-core/src/statistics/event/listener.rs 80.00% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1479      +/-   ##
===========================================
- Coverage    84.48%   84.36%   -0.13%     
===========================================
  Files          256      253       -3     
  Lines        19843    19783      -60     
  Branches     19843    19783      -60     
===========================================
- Hits         16765    16690      -75     
- Misses        2763     2784      +21     
+ Partials       315      309       -6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@josecelano josecelano changed the title Overhaul stats: Extract events package Overhaul stats: Extract events package (part 1) Apr 25, 2025
@josecelano

Copy link
Copy Markdown
Member Author

ACK b0951aa

@josecelano
josecelano marked this pull request as ready for review April 25, 2025 18:11
@josecelano
josecelano merged commit 419f790 into torrust:develop Apr 25, 2025
@da2ce7 da2ce7 mentioned this pull request Nov 25, 2026
8 tasks done
@da2ce7

da2ce7 commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

Post-merge note: this pull request requested a review from this account and was closed without one at its final head. A post-merge review will not be done: Only 107 of the 386 executable lines it added remain on the default branch, at their own paths or in the files those paths were later renamed to; the rest has since been rewritten or removed.

This branch was previously deployed

1 inactive deployment
coverage — b0951aad Deployed Apr 25, 2025 by josecelano
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

- Developer - Torrust Improvement Experience Code Cleanup / Refactoring Tidying and Making Neat

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Overhaul stats: Extract events package (part 1)

2 participants