Skip to content

feat: add metrics publisher for NT#1791

Merged
Gold856 merged 25 commits intoPhotonVision:mainfrom
samfreund:feat-publish-coprocessor-metrics
Jul 12, 2025
Merged

feat: add metrics publisher for NT#1791
Gold856 merged 25 commits intoPhotonVision:mainfrom
samfreund:feat-publish-coprocessor-metrics

Conversation

@samfreund
Copy link
Member

@samfreund samfreund commented Feb 19, 2025

Publishes metrics to NT using a protobuf under photonvision/coprocessors/metrics using the device host name as the key.

Refactors metrics to use numbers where possible, instead of strings.

Removes metrics from card when they can't be determined for platform.

Updates UI metrics periodically.

Resolves #1988

Closes #830

@samfreund samfreund requested a review from a team as a code owner February 19, 2025 18:22
@samfreund samfreund marked this pull request as draft February 19, 2025 18:22
@samfreund

This comment was marked as resolved.

@mcm001

This comment was marked as resolved.

@Gold856 Gold856 linked an issue Mar 20, 2025 that may be closed by this pull request
@mcm001 mcm001 force-pushed the feat-publish-coprocessor-metrics branch from 2432619 to ee9d7ed Compare April 13, 2025 17:50
@mcm001
Copy link
Contributor

mcm001 commented Apr 13, 2025

Refactored to publish a protobuf, not sure if this actually better but
image

@mcm001

This comment was marked as resolved.

@samfreund samfreund added the enhancement New feature or request label Apr 14, 2025
@samfreund

This comment was marked as outdated.

@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch from 5630f52 to fa708a0 Compare July 4, 2025 23:38
@samfreund samfreund marked this pull request as ready for review July 5, 2025 18:01
@Gold856

This comment was marked as resolved.

@samfreund

This comment was marked as outdated.

@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch 2 times, most recently from ecbda3a to cded102 Compare July 10, 2025 04:57
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch 2 times, most recently from d1f1409 to 5f5f274 Compare July 12, 2025 06:06
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch from 5f5f274 to 33dddf3 Compare July 12, 2025 06:12
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch 2 times, most recently from 7f712e8 to 55319e1 Compare July 12, 2025 06:20
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch from e342c60 to 56aadeb Compare July 12, 2025 06:36
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch from 56aadeb to 71b5843 Compare July 12, 2025 06:39
@samfreund samfreund force-pushed the feat-publish-coprocessor-metrics branch from 71b5843 to 0ac0f39 Compare July 12, 2025 06:40
Gold856
Gold856 previously approved these changes Jul 12, 2025
@Gold856 Gold856 enabled auto-merge (squash) July 12, 2025 06:42
Gold856
Gold856 previously approved these changes Jul 12, 2025
@Gold856 Gold856 force-pushed the feat-publish-coprocessor-metrics branch from ede2f6d to d7941a7 Compare July 12, 2025 08:36
@Gold856 Gold856 force-pushed the feat-publish-coprocessor-metrics branch from d7941a7 to 9b79cf0 Compare July 12, 2025 08:53
@Gold856 Gold856 merged commit 7f6edcd into PhotonVision:main Jul 12, 2025
64 of 65 checks passed
@samfreund samfreund deleted the feat-publish-coprocessor-metrics branch July 13, 2025 18:00
@Gold856 Gold856 added the backend Things relating to photon-core and photon-server label Aug 4, 2025
Gold856 added a commit that referenced this pull request Aug 11, 2025
## Description

After #1991, the program state was always resent in an attempt to
simplify logic, but this had the side effect of causing the settings UI
to reset periodically when the hostname check was performed. This
restores the original logic in #1791 to check for differences in the
conflict state, and to only send the program state if it's changed.

## Meta

Merge checklist:
- [x] Pull Request title is [short, imperative
summary](https://cbea.ms/git-commit/) of proposed changes
- [x] The description documents the _what_ and _why_
- [ ] If this PR changes behavior or adds a feature, user documentation
is updated
- [ ] If this PR touches photon-serde, all messages have been
regenerated and hashes have not changed unexpectedly
- [ ] If this PR touches configuration, this is backwards compatible
with settings back to v2024.3.1
- [ ] If this PR touches pipeline settings or anything related to data
exchange, the frontend typing is updated
- [ ] If this PR addresses a bug, a regression test for it is added
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend Things relating to photon-core and photon-server enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add host stats on NetworkTables

5 participants