Skip to content

Conversation

@flesher0813
Copy link
Contributor

@flesher0813 flesher0813 commented Dec 8, 2025

Purpose

What this PR does / why we need it?

This pull request (PR) supports collecting different statistics aggregated by the monitor component from both the Python side (e.g., ucm_connector) and the C++ side (e.g., various stores), and provides a unified interface for users to retrieve such statistics.
Therefore, this PR modifies the current metrics structure in three aspects:

  • Implements the Python-side statistics and decouples the implementation from the framework structure.
  • Exposes the interfaces required for registering, creating, updating, retrieving, and clearing statistics via global functions, and exposes these interfaces to Python through pybind11 to ensure that both languages can access the same instance within a single process.
  • Provides the examples and documentation.

Modifications

Does this PR introduce any user-facing change?

Users can add or remove the statics to be collected according to the documentation for custom metrics.

Test

How was this patch tested?

Tested with

ucm/shared/test/case/metrics/monitor_test.cc
ucm/shared/test/example/metrics/monitor_stats_example.py
image image

doc
image

@flesher0813 flesher0813 force-pushed the develop branch 8 times, most recently from bc0245b to 5438839 Compare December 11, 2025 03:24
@flesher0813 flesher0813 changed the title [WIP] Support metrics across language boundary [Feat] Support metrics across language boundary Dec 11, 2025
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.

2 participants