Merge "Don't spam consecutive parent suppressions in NotifLog." into tm-qpr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
7ab95c8470
@@ -1160,12 +1160,21 @@ public class ShadeListBuilder implements Dumpable, PipelineDumpable {
|
|||||||
mLogger.logParentChanged(mIterationCount, prev.getParent(), curr.getParent());
|
mLogger.logParentChanged(mIterationCount, prev.getParent(), curr.getParent());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (curr.getSuppressedChanges().getParent() != null) {
|
GroupEntry currSuppressedParent = curr.getSuppressedChanges().getParent();
|
||||||
mLogger.logParentChangeSuppressed(
|
GroupEntry prevSuppressedParent = prev.getSuppressedChanges().getParent();
|
||||||
|
if (currSuppressedParent != null && (prevSuppressedParent == null
|
||||||
|
|| !prevSuppressedParent.getKey().equals(currSuppressedParent.getKey()))) {
|
||||||
|
mLogger.logParentChangeSuppressedStarted(
|
||||||
mIterationCount,
|
mIterationCount,
|
||||||
curr.getSuppressedChanges().getParent(),
|
currSuppressedParent,
|
||||||
curr.getParent());
|
curr.getParent());
|
||||||
}
|
}
|
||||||
|
if (prevSuppressedParent != null && currSuppressedParent == null) {
|
||||||
|
mLogger.logParentChangeSuppressedStopped(
|
||||||
|
mIterationCount,
|
||||||
|
prevSuppressedParent,
|
||||||
|
prev.getParent());
|
||||||
|
}
|
||||||
|
|
||||||
if (curr.getSuppressedChanges().getSection() != null) {
|
if (curr.getSuppressedChanges().getSection() != null) {
|
||||||
mLogger.logSectionChangeSuppressed(
|
mLogger.logSectionChangeSuppressed(
|
||||||
|
|||||||
@@ -193,7 +193,7 @@ class ShadeListBuilderLogger @Inject constructor(
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun logParentChangeSuppressed(
|
fun logParentChangeSuppressedStarted(
|
||||||
buildId: Int,
|
buildId: Int,
|
||||||
suppressedParent: GroupEntry?,
|
suppressedParent: GroupEntry?,
|
||||||
keepingParent: GroupEntry?
|
keepingParent: GroupEntry?
|
||||||
@@ -207,6 +207,21 @@ class ShadeListBuilderLogger @Inject constructor(
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fun logParentChangeSuppressedStopped(
|
||||||
|
buildId: Int,
|
||||||
|
previouslySuppressedParent: GroupEntry?,
|
||||||
|
previouslyKeptParent: GroupEntry?
|
||||||
|
) {
|
||||||
|
buffer.log(TAG, INFO, {
|
||||||
|
long1 = buildId.toLong()
|
||||||
|
str1 = previouslySuppressedParent?.logKey
|
||||||
|
str2 = previouslyKeptParent?.logKey
|
||||||
|
}, {
|
||||||
|
"(Build $long1) Change of parent to '$str1' no longer suppressed; " +
|
||||||
|
"replaced parent '$str2'"
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
fun logGroupPruningSuppressed(
|
fun logGroupPruningSuppressed(
|
||||||
buildId: Int,
|
buildId: Int,
|
||||||
keepingParent: GroupEntry?
|
keepingParent: GroupEntry?
|
||||||
|
|||||||
Reference in New Issue
Block a user