-
Notifications
You must be signed in to change notification settings - Fork 10.5k
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
[NEW] Statistics about language usage #20832
Conversation
07917df
to
0470102
Compare
@@ -31,6 +31,16 @@ const setPrometheusData = async () => { | |||
metrics.ddpAuthenticatedSessions.set(authenticatedSessions.length); | |||
metrics.ddpConnectedUsers.set(_.unique(authenticatedSessions.map((s) => s.userId)).length); | |||
|
|||
// Apps metrics |
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.
moved this up because it was not running if no statistics were found https://github.com/RocketChat/Rocket.Chat/pull/20832/files#diff-d5557cb19a93c53e1e732cf0f6ca3ef772654b5a9fc40fa9f92092f6d304d196R45
@@ -4,7 +4,7 @@ export class Statistics extends Base { | |||
constructor() { | |||
super('statistics'); | |||
|
|||
this.tryEnsureIndex({ createdAt: 1 }); | |||
this.tryEnsureIndex({ createdAt: -1 }); |
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.
the only find using this index was findLast and it sorts on reverse order
Proposed changes (including videos or screenshots)
track what languages get picked the most as preferred ui language.
Issue(s)
Steps to test or reproduce
Further comments