Page MenuHomePhabricator

[keyserver] Add param to getRetention to customize activity period being checked
ClosedPublic

Authored by ashoat on Nov 25 2024, 11:59 AM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Dec 26, 6:35 PM
Unknown Object (File)
Thu, Dec 26, 5:58 PM
Unknown Object (File)
Thu, Dec 26, 5:57 PM
Unknown Object (File)
Thu, Dec 26, 5:54 PM
Unknown Object (File)
Thu, Dec 26, 5:19 PM
Unknown Object (File)
Thu, Dec 26, 8:31 AM
Unknown Object (File)
Thu, Dec 26, 1:48 AM
Unknown Object (File)
Mon, Dec 16, 1:06 PM
Subscribers

Details

Summary

We want to introduce new metrics that check retention based on usage in the last week rather than usage in the last day. This will be handled in the next diff, but first we want to factor out the param.

Test Plan

Ran it on my personal server and confirmed that a message appeared with the correct metrics

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

varun added inline comments.
keyserver/src/cron/metrics.js
78 ↗(On Diff #46040)
100 ↗(On Diff #46040)

shouldn't we rename this variable? maybe xDaysAgo or something

111 ↗(On Diff #46040)

should this param default to 1 to match the function description?

This revision is now accepted and ready to land.Nov 25 2024, 2:02 PM
keyserver/src/cron/metrics.js
111 ↗(On Diff #46040)

actually we probably want to just update the code comment above. specifically the second sentence

This revision was landed with ongoing or failed builds.Nov 25 2024, 2:25 PM
This revision was automatically updated to reflect the committed changes.