prefect.server.events.storage
process_time_based_counts(filter, time_unit, time_interval, counts)
Common logic for processing time-based counts across different event backends.
When doing time-based counting we want to do two things:
- Backfill any missing intervals with 0 counts.
- Update the start/end times that are emitted to match the beginning and end of the intervals rather than having them reflect the true max/min occurred time of the events themselves.
Source code in src/prefect/server/events/storage/__init__.py
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 |
|