Skip to content

Dashboard generator refactors - #7809

Open
bendk wants to merge 3 commits into
mozilla:mainfrom
bendk:bdk/push-worutumwlxyx
Open

bendk wants to merge 3 commits into
mozilla:mainfrom
bendk:bdk/push-worutumwlxyx

Conversation

@bendk

@bendk bendk commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

This PR contains a bunch of commits that are mostly refactors, although some change minor functionality. I'd recommend viewing each one separately.

The overall goal is to make it easier for teams to configure their dashboards, especially for teams that don't have a ton of app-services experience. Specifically, I wanted to make it easier to add new team configuration and add new metric types.

I imported the new .json files to our yardstick dashboards, so you can go there to see the new version.

Pull Request checklist

  • Breaking changes: This PR follows our breaking change policy
    • This PR follows the breaking change policy:
      • This PR has no breaking API changes, or
      • There are corresponding PRs for our consumer applications that resolve the breaking changes and have been approved
  • Quality: This PR builds and tests run cleanly
    • Note:
      • For changes that need extra cross-platform testing, consider adding [ci full] to the PR title.
      • If this pull request includes a breaking change, consider cutting a new release after merging.
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Changelog: This PR includes a changelog entry in CHANGELOG.md or an explanation of why it does not need one
    • Any breaking changes to Swift or Kotlin binding APIs are noted explicitly
  • Dependencies: This PR follows our dependency management guidelines
    • Any new dependencies are accompanied by a summary of the due diligence applied in selecting them.

@bendk
bendk requested a review from skhamis November 19, 2026 18:44
Use regular strings instead of the Component enum.
This makes it easier for teams to configure their dashboards, since they
don't need to define a new variant.

* Removed `Component::applications()`.  We now always include all
  applications in the dropdown filter and always create rows in the
  component errors section for all applications. That's what we want for
  all current teams and if there's a future team that doesn't ship to
  some application, it's easy enough for them to ignore the blank row.
* Made the component filter only apply to the error panel and not the
  sync metrics panel. The old way was confusing since some components
  have multiple sync engines or none.  Instead, users can just click the
  panel to filter.
* Replaced `Component::sync_engines()` with `TeamConfig::sync_engines`.
  It seems simpler to just list a team's sync engines, especially since
  this will be the empty list for a lot of teams.  I also like that this
  makes things more explicit.
* Fixed fxa reporting to always use the `fxa-client` prefix, not
  `fxaclient`.  Claude noticed that we weren't being consistent there.
  If I was designing this again, I'd prefer not having the dash in the
  prefix, but I don't want to make that change now since we already have
  a bunch of data with `fxa-client`.

I considered replacing `SyncEngine` with a string as well, but I think
the enum has more value there since we need more special-cased logic
(e.g. which engines are available on which applications).  Also, teams
are less likely to add new sync engines, so the extra friction is not as
big of a deal.
Removed the Metric enum.  Instead, each team now gets a function to
build their dashboard(s) and they call the metric functions directly.
Moved `components` and `sync_engines` out of `TeamConfig` and pass them to
the dashboard builder functions directly.

I like this because it's a simpler system overall.  To define a new
metric type, you just need to define the dashboard builder functions and
you're ready to start using it.  No need to add variants or update
matches. Also, it's nice that you can use LSP-Goto Definition to go
directly from the team module to the metrics code.

Move the metric struct definitions to the submodule inside `metrics`.

Give each team a dedicated module to configure its dashboard.  The sync
team's configuration was getting pretty long so I thought it should be
split out.
Use builder methods for common operations.  This makes the metrics and
team config code easier to write and understand.

Also:
 * Enable Desktop error ping on the error details page.
 * Rename `client_count` to `count` on the event query.
   This makes the column names the same for the UNION expression.
@bendk
bendk force-pushed the bdk/push-worutumwlxyx branch from c2a0978 to 8e5b8a2 Compare November 19, 2026 20:32

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant