discourse/app/models/concerns
Gabriel Grubba 8d28038666
FEATURE: Add WebHookEventsDailyAggregate report page (#27573)
* FEATURE: Add WebHookEventsDailyAggregate

Add WebHookEventsDailyAggregate model to store daily aggregates of web hook events.
Add AggregateWebHooksEvents job to aggregate web hook events daily.
Add spec for WebHookEventsDailyAggregate model.

* DEV: Update annotations for web_hook_events_daily_aggregate.rb

* DEV: Update app/jobs/scheduled/aggregate_web_hooks_events.rb

Co-authored-by: Martin Brennan <martin@discourse.org>

* DEV: Address review feedback

Solves:
- https://github.com/discourse/discourse/pull/27542#discussion_r1646961101
- https://github.com/discourse/discourse/pull/27542#discussion_r1646958890
- https://github.com/discourse/discourse/pull/27542#discussion_r1646976808
- https://github.com/discourse/discourse/pull/27542#discussion_r1646979846
- https://github.com/discourse/discourse/pull/27542#discussion_r1646981036

* A11Y: Add translation to retain_web_hook_events_aggregate_days key

* FEATURE: Purge old web hook events daily aggregate

Solves: https://github.com/discourse/discourse/pull/27542#discussion_r1646961101

* DEV:  Update tests for web_hook_events_daily_aggregate

Update WebHookEventsDailyAggregate to not use save! at the end
Solves: https://github.com/discourse/discourse/pull/27542#discussion_r1646984601

* PERF: Change job query to use WebHook table instead of WebHookEvent table

* DEV: Update tests to use `fab!`

* DEV: Address code review feedback.

Add idempotency to job
Add has_many to WebHook

* FEATURE: Add WebHookEventsDailyAggregate report page

Add locales for the new report page
Reorder imports in the report.rb

* DEV: Remove logger line

* FEATURE: Add `auto_insert_none_item` option to `report-filters` components

---------

Co-authored-by: Martin Brennan <martin@discourse.org>
2024-06-27 10:26:42 -03:00
..
reports FEATURE: Add WebHookEventsDailyAggregate report page (#27573) 2024-06-27 10:26:42 -03:00
anon_cache_invalidator.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
cached_counting.rb DEV: In test, if flush is called and there is no thread, flush inline (#21426) 2023-05-08 13:25:00 +10:00
category_hashtag.rb DEV: Remove enable_experimental_hashtag_autocomplete logic (#22820) 2023-08-08 11:18:55 +10:00
custom_field.rb DEV: Add true_fields method for CustomFields (#24876) 2023-12-14 11:06:21 -06:00
has_custom_fields.rb FIX: do not use return in block (#26260) 2024-03-20 10:49:28 +01:00
has_deprecated_columns.rb DEV: Remove version-number-based logic (#25482) 2024-01-30 17:34:10 +00:00
has_destroyed_web_hook.rb FEATURE: granular webhooks (#23070) 2023-10-09 03:35:31 +00:00
has_sanitizable_fields.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
has_search_data.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
has_url.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
limited_edit.rb FIX: Always trust admin and moderators with post edits (#25602) 2024-02-08 13:10:26 +10:00
positionable.rb FIX: Update position on model when re-positioning record (#24997) 2023-12-21 10:15:10 +08:00
roleable.rb DEV: Make more group-based settings client: false (#25585) 2024-02-08 09:43:34 +10:00
searchable.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
second_factor_manager.rb DEV: Fix various rubocop lints (#24749) 2023-12-06 23:25:00 +01:00
stats_cacheable.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
topic_tracking_state_publishable.rb DEV: Apply syntax_tree formatting to app/* 2023-01-09 14:14:59 +00:00
trashable.rb DEV: Added .only_deleted scope in the Trashable module (#20196) 2023-02-07 15:28:59 -03:00