Add platform information for push notification metrics (#27460)

* Add platform information for push notification metrics

* Address feedback

* Add the client platform returned by the devices to the normalize function

* Add "no platform" platform label to distinguish from unknown
Этот коммит содержится в:
Daniel Espino García
2024-07-05 09:34:01 +02:00
коммит произвёл GitHub
родитель 6bbf7bbb9f
Коммит e5a3dd7fea
15 изменённых файлов: 122 добавлений и 105 удалений

Просмотреть файл

@@ -42,7 +42,7 @@ func (a *App) SaveAcknowledgementForPost(c request.CTX, postID, userID string) (
}
if appErr := a.ResolvePersistentNotification(c, post, userID); appErr != nil {
a.CountNotificationReason(model.NotificationStatusError, model.NotificationTypeWebsocket, model.NotificationReasonResolvePersistentNotificationError)
a.CountNotificationReason(model.NotificationStatusError, model.NotificationTypeWebsocket, model.NotificationReasonResolvePersistentNotificationError, model.NotificationNoPlatform)
a.NotificationsLog().Error("Error resolving persistent notification",
mlog.String("sender_id", userID),
mlog.String("post_id", post.RootId),