Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/NotifCollection.java +2 −0 Original line number Diff line number Diff line Loading @@ -326,6 +326,8 @@ public class NotifCollection implements Dumpable { entry.getSbn().setOverrideGroupKey(newOverrideGroupKey); } } } else { mLogger.logRankingMissing(entry.getKey(), rankingMap); } } } Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/notifcollection/NotifCollectionLogger.kt +16 −5 Original line number Diff line number Diff line Loading @@ -16,8 +16,11 @@ package com.android.systemui.statusbar.notification.collection.notifcollection import android.service.notification.NotificationListenerService.RankingMap import com.android.systemui.log.LogBuffer import com.android.systemui.log.LogLevel import com.android.systemui.log.LogLevel.DEBUG import com.android.systemui.log.LogLevel.INFO import com.android.systemui.log.LogLevel.WARNING import com.android.systemui.log.dagger.NotificationLog import javax.inject.Inject Loading @@ -25,7 +28,7 @@ class NotifCollectionLogger @Inject constructor( @NotificationLog private val buffer: LogBuffer ) { fun logNotifPosted(key: String) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key }, { "POSTED $str1" Loading @@ -33,7 +36,7 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifGroupPosted(groupKey: String, batchSize: Int) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = groupKey int1 = batchSize }, { Loading @@ -42,7 +45,7 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifUpdated(key: String) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key }, { "UPDATED $str1" Loading @@ -50,13 +53,21 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifRemoved(key: String, reason: Int) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key int1 = reason }, { "REMOVED $str1 reason=$int1" }) } fun logRankingMissing(key: String, rankingMap: RankingMap) { buffer.log(TAG, WARNING, { str1 = key }, { "Ranking update is missing ranking for $str1" }) buffer.log(TAG, DEBUG, {}, { "Ranking map contents:" }) for (entry in rankingMap.orderedKeys) { buffer.log(TAG, DEBUG, { str1 = entry }, { " $str1" }) } } } private const val TAG = "NotifCollection" No newline at end of file Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/NotifCollection.java +2 −0 Original line number Diff line number Diff line Loading @@ -326,6 +326,8 @@ public class NotifCollection implements Dumpable { entry.getSbn().setOverrideGroupKey(newOverrideGroupKey); } } } else { mLogger.logRankingMissing(entry.getKey(), rankingMap); } } } Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/notifcollection/NotifCollectionLogger.kt +16 −5 Original line number Diff line number Diff line Loading @@ -16,8 +16,11 @@ package com.android.systemui.statusbar.notification.collection.notifcollection import android.service.notification.NotificationListenerService.RankingMap import com.android.systemui.log.LogBuffer import com.android.systemui.log.LogLevel import com.android.systemui.log.LogLevel.DEBUG import com.android.systemui.log.LogLevel.INFO import com.android.systemui.log.LogLevel.WARNING import com.android.systemui.log.dagger.NotificationLog import javax.inject.Inject Loading @@ -25,7 +28,7 @@ class NotifCollectionLogger @Inject constructor( @NotificationLog private val buffer: LogBuffer ) { fun logNotifPosted(key: String) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key }, { "POSTED $str1" Loading @@ -33,7 +36,7 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifGroupPosted(groupKey: String, batchSize: Int) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = groupKey int1 = batchSize }, { Loading @@ -42,7 +45,7 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifUpdated(key: String) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key }, { "UPDATED $str1" Loading @@ -50,13 +53,21 @@ class NotifCollectionLogger @Inject constructor( } fun logNotifRemoved(key: String, reason: Int) { buffer.log(TAG, LogLevel.INFO, { buffer.log(TAG, INFO, { str1 = key int1 = reason }, { "REMOVED $str1 reason=$int1" }) } fun logRankingMissing(key: String, rankingMap: RankingMap) { buffer.log(TAG, WARNING, { str1 = key }, { "Ranking update is missing ranking for $str1" }) buffer.log(TAG, DEBUG, {}, { "Ranking map contents:" }) for (entry in rankingMap.orderedKeys) { buffer.log(TAG, DEBUG, { str1 = entry }, { " $str1" }) } } } private const val TAG = "NotifCollection" No newline at end of file