-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: handle analytics data after expiry #202
Conversation
f2211a5
to
25bc1ed
Compare
25bc1ed
to
95a7192
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it lgtm, I am just used of storing the unix timestamp (in seconds). Using millis is fine as long as it is expected. Any reason why you preferred millis over seconds?
)] | ||
pub async fn handler( | ||
State(state): State<Arc<AppState>>, | ||
Query(query): Query<GetQuestsQuery>, | ||
) -> impl IntoResponse { | ||
let current_time = chrono::Utc::now().timestamp_millis(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't it be in seconds?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I personally make it miliseconds to make it precise in all cases. Not that it's very relevant for our usecase but i followed this convention in other endpoints like tasks and boosts too.Do you think i should change this to seconds?
Probabyl doesn't require a change but just an explanation :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
We need to stop using data for analytics for tasks completion of the quest once the quest has expired. This data is irrelevant and we would need to remove it from the stats dashboard.
We also modify the document model for to add some kind of automation on quests -
https://www.notion.so/lfg-labs/Quest-DB-Update-6a216557a4084a60a5cd744f07c8a92a?pvs=4