Files
brave-core/rewrite
Claudio DeSouza d38d733dde [cr149] PageActionPerActionMetricsRecorder renamed
This PR fixes the plaster for `PageActionPerActionMetricsRecorder`,
which has to use the new `PageActionMetricsRecorder`. This PR also
improves the plaster to disable any `Record` functions in this class, so
we can notified when new ones are added.

Chromium changes:
https://chromium.googlesource.com/chromium/src/+/42d106dd97f5729ff8ccf50171f3dc87798d76d8

commit 42d106dd97f5729ff8ccf50171f3dc87798d76d8
Author: Kaan Alsan <alsan@chromium.org>
Date:   Fri Apr 24 14:29:50 2026 -0700

    Consolidate PageAction Metrics Recording using ScopedMultiSourceObservation

    This CL transitions the PageAction metrics recording system from
    multiple ScopedObservation-based recorders to a single
    PageActionMetricsRecorder using ScopedMultiSourceObservation.

    Previously, we had count(page actions) * count(tabs) metrics recorder
    objects, which duplicated GURLs and created many individual scoped
    observations. This CL improves efficiency by sharing navigation state
    across all actions in a tab and reducing the total number of
    observations. With local profiling (with debug parameters on), this
    saves ~100KB per tab, with 31 page actions enabled.

    Key changes:
    - Merged per-action and page-level metrics logic into a unified
      PageActionMetricsRecorder.
    - Updated PageActionModelInterface to include GetActionId() for
      identification in the consolidated recorder.
    - Refactored PageActionControllerImpl to manage the unified recorder.
    - Deleted the redundant PageActionPageMetricsRecorder.
    - Updated unit tests and test support classes to align with the new
      architecture.

    Bug: 384074251
    Change-Id: I1aeb2205b4d36de3af68d70404ce459babf1dbef
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7790756
    Commit-Queue: Kaan Alsan <alsan@chromium.org>
    Reviewed-by: Foromo Daniel Soromou <koretadaniel@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#1620471}
2026-05-22 16:25:14 -04:00
..