Commit 9b82d78
Lasim
feat(metrics): add MCP client activity metrics endpoint and service
- Implemented a new Fastify route for retrieving MCP client activity metrics, including request counts, tool calls, and active clients over specified time ranges and intervals.
- Created McpClientActivityMetricsService to handle the logic for querying and aggregating metrics data from the database.
- Introduced TimeSeriesMetricsService as a base class for shared time-series metric functionalities, including time range parsing, bucket generation, and summary calculations.
- Defined schemas for request query parameters and response formats to ensure proper validation and documentation.
- Enhanced error handling and logging for better traceability of issues during metric retrieval.1 parent 722811a commit 9b82d78
File tree
10 files changed
+5134
-16
lines changed- services/backend
- drizzle/migrations_sqlite
- meta
- src
- db
- events/satellite
- permissions
- routes
- users/me/metrics/mcp
- services/metrics
10 files changed
+5134
-16
lines changedLines changed: 21 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
0 commit comments