Skip to content

Tibi holmes#5118

Draft
theTibi wants to merge 132 commits intotibi-testfrom
tibi-holmes
Draft

Tibi holmes#5118
theTibi wants to merge 132 commits intotibi-testfrom
tibi-holmes

Conversation

@theTibi
Copy link
Copy Markdown
Contributor

@theTibi theTibi commented Mar 6, 2026

PMM-0

Link to the Feature Build: SUBMODULES-0

If this PR adds, removes or alters one or more API endpoints, please review and add or update the relevant API documentation as well:

  • API Docs updated

If this PR is related to some other PRs in this or other repositories, please provide links to those PRs:

  • Links to related pull requests (optional).

fabio-silva and others added 13 commits January 22, 2026 13:13
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
- Settings: Add Adre struct (Enabled, URL), IsAdreEnabled(), GetAdreURL()
- ChangeSettingsParams: Add EnableAdre, AdreURL for updates
- New package managed/services/adre: HolmesGPT HTTP client
  - Models(), Chat(), ChatStream(), Investigate(), InvestigateStream()
  - Uses HolmesGPT /api/chat, /api/stream/chat, /api/investigate, etc.

Made-with: Cursor
- Introduced new HTTP handlers for ADRE settings, models, chat, alerts, and investigation endpoints in the pmm-managed service.
- Updated the Grafana auth server to include permissions for ADRE routes.
- Added navigation support for ADRE in the UI, including a dedicated page and chat widget.
- Enhanced the main application layout to incorporate the ADRE chat widget.

Made-with: Cursor
@theTibi theTibi requested review from a team as code owners March 6, 2026 23:59
@theTibi theTibi requested review from JiriCtvrtka, fabio-silva, matejkubinec and maxkondr and removed request for a team March 6, 2026 23:59
@theTibi theTibi marked this pull request as draft March 6, 2026 23:59
@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 7, 2026

Codecov Report

❌ Patch coverage is 0.88106% with 225 lines in your changes missing coverage. Please review.
✅ Project coverage is 46.63%. Comparing base (6a44b81) to head (edd9053).

Files with missing lines Patch % Lines
...panel/components/Details/AiInsights/AiInsights.tsx 0.00% 195 Missing ⚠️
...omponents/Details/AiInsights/AiInsights.service.ts 0.00% 18 Missing ⚠️
...p/src/pmm-qan/panel/components/Details/Details.tsx 0.00% 8 Missing ⚠️
managed/cmd/pmm-managed/main.go 0.00% 4 Missing ⚠️
Additional details and impacted files
@@              Coverage Diff              @@
##           tibi-test    #5118      +/-   ##
=============================================
- Coverage      47.57%   46.63%   -0.94%     
=============================================
  Files            414      553     +139     
  Lines          42177    44861    +2684     
  Branches           0      664     +664     
=============================================
+ Hits           20065    20921     +856     
- Misses         20134    21944    +1810     
- Partials        1978     1996      +18     
Flag Coverage Δ
admin 34.42% <ø> (ø)
agent 53.11% <ø> (-0.22%) ⬇️
unittests 37.81% <0.00%> (?)
vmproxy 72.09% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

theTibi added 7 commits March 7, 2026 10:51
- Modified README to clarify ADRE settings access for viewers and admins.
- Enhanced ChatStream functionality to handle streaming requests more effectively.
- Added URL validation in PostSettings handler to ensure proper format.
- Updated Grafana auth server to allow viewer access to ADRE settings.
- Improved error handling in AdrePage to manage loading states and forbidden access.
- Refactored AdreChatWidget to remove unused model fetching logic.
- Introduced a utility function to parse and extract text from SSE data in chat streams.

Made-with: Cursor
- Updated README to specify that alerts require ADRE to be enabled.
- Modified ChatStream to avoid mutating the original request.
- Added comprehensive tests for ADRE settings and model retrieval.
- Improved URL validation in PostSettings handler to ensure proper format and provide clearer error messages.
- Enhanced error handling in various ADRE handlers to ensure consistent responses.

Made-with: Cursor
- Changed the ChatStream HTTP request URL from /api/stream/chat to /api/chat for consistency.
- Enhanced error message formatting in ChatStream to clarify the source of errors related to the new endpoint.

Made-with: Cursor
- Updated ADRE handlers to fetch alerts from Grafana's Alertmanager instead of VMAlert.
- Modified README to reflect the change in alert source.
- Enhanced error handling and added tests for the new alert fetching functionality.
- Refactored related components to improve clarity and maintainability.

Made-with: Cursor
- Added support for Basic Authentication in the ADRE client by encoding credentials in the Authorization header.
- Updated README to include instructions for using authentication with HolmesGPT URLs.
- Improved error handling in the InvestigateStream method to clarify endpoint usage.

Made-with: Cursor
- Updated the buildInvestigatePayload function to include optional context and subject fields as records.
- Improved the structure of the subject field to encapsulate alert details more effectively.
- Ensured that the context field provides additional information about the alert source and count.

Made-with: Cursor
…handling

- Updated adreChatStream to accept a callback for both content and reasoning chunks, improving the response structure.
- Refactored SSE data parsing to return content and reasoning separately, enhancing clarity and usability.
- Modified AdreChatPanel to store and display reasoning alongside chat messages, improving user experience.
- Improved local storage handling to accommodate reasoning data, ensuring persistence across sessions.

Made-with: Cursor
matejkubinec and others added 12 commits April 6, 2026 12:22
* PMM-14951 Fix timezone menu link variable

* PMM-14951 Update getLinkUrl implementation to keep sync with grafana

* PMM-14951 Update comment

---------

Co-authored-by: Fábio Silva <ffjs1993@gmail.com>
* PMM-14825 Fix tests related to disabling telemetry in FB

* PMM-14825 Fix API agent test

* PMM-14825 Fix API agent test, follow up on review

* PMM-14825 Follow up on review

* PMM-14825 Add a unit test

* PMM-14825 Refactor the code and unit test

* PMM-14825 Fix empty ds lookup failure
…5217)

Agent-Logs-Url: https://github.com/percona/pmm/sessions/dc400a49-230f-400c-a20e-a4f893760826

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ademidoff <81549+ademidoff@users.noreply.github.com>
Co-authored-by: Alex Demidoff <alexander.demidoff@percona.com>
* Follow up on PR review

* chore: trigger the build

* Fix a broken link
…agent

- Introduced `daemonset.example.yaml` as a reference for deploying the coroot-node-agent in Kubernetes, including configuration for security context, resource limits, and volume mounts.
- Added a README file to provide guidance on using the coroot-node-agent with PMM, detailing installation steps, configuration options, and best practices for deployment.
- Enhanced documentation for OTEL ClickHouse schema alignment and rollout strategies, ensuring clarity on database management and schema creation.
@it-percona-cla
Copy link
Copy Markdown
Contributor

it-percona-cla commented Apr 8, 2026

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
4 out of 5 committers have signed the CLA.

✅ fabio-silva
✅ matejkubinec
✅ theTibi
✅ ademidoff
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

theTibi added 17 commits April 9, 2026 16:27
…ations

- Introduced a new interactive service map panel for PMM, visualizing service connections and synchronized trace data.
- Added configuration files including ESLint and TypeScript settings for the new panel.
- Created a comprehensive README detailing features, data sources, build, and deployment instructions.
- Implemented various components for the service map, including namespace filtering and service node representation.
- Updated .gitignore to include build artifacts for the new panel.

This commit lays the foundation for enhanced observability in PMM through the service map visualization.
- Enhanced GitHub Actions workflow to include caching for both pmm-app and pmm-service-map dependencies.
- Updated Grafana configuration to allow loading of the new pmm-service-map-panel plugin.
- Incremented RPM release version to 24 and included the pmm-service-map-panel in the percona-dashboards RPM.
- Modified Makefile to install and build dependencies for both pmm-app and pmm-service-map.
- Updated the OTel ClickHouse dashboard JSON to use the new ClickHouse-OTEL datasource.
- Revised README for the pmm-service-map to clarify deployment instructions within PMM.

These changes improve the integration and deployment of the new service map panel, enhancing observability in PMM.
- Introduced a new AI Insights tab in the Details section, allowing users to access AI-generated analysis for queries.
- Implemented the AiInsights component to handle fetching and displaying insights, including loading states and error handling.
- Added constants and messages for the new tab, including various user notifications and actions.
- Created a service for API interactions related to AI insights, including fetching insights and creating ServiceNow tickets.
- Updated the Details component to integrate the new AI Insights tab and manage its visibility based on query context.

These changes enhance the user experience by providing actionable insights directly within the PMM interface.
- Updated error handling to include additional PostgreSQL error codes for invalid authorization and password issues.
- Improved the initWithRoot function to read the PostgreSQL password from a secure file, enhancing security during database creation.
- Refined error messages for better clarity and debugging, ensuring that failures in database and user creation are properly reported.

These changes improve the robustness and security of the database setup process in the application.
- Added a new function `runPMMAgentSetupHA` to handle the setup of PMM agents in high availability (HA) configurations.
- Enhanced the `setupPMMServerHAAgents` function to check for existing nodes and reuse their PMM agent IDs, improving the handling of existing inventory.
- Updated error handling to ensure proper feedback when nodes or agents are not found, and to log relevant information during the setup process.

These changes streamline the PMM agent setup process in HA environments, ensuring better integration with existing configurations.
…d configurations

- Added default vmalert recording rules for PMM Service Map, improving monitoring capabilities.
- Updated package.json to include new development dependencies for testing.
- Enhanced README to clarify the inclusion of default recording rules and their usage.
- Adjusted node dimensions for better visualization in the service map.
- Introduced new options for grouping by pod and hiding weak edges, enhancing user control over displayed data.
- Improved the service map panel with additional settings for TCP port filtering and edge visibility.

These changes significantly enhance the functionality and usability of the PMM service map panel, providing users with more control and better insights into their service topology.
…ures

- Added new handlers for managing ADRE conversations, including listing, creating, updating, and deleting conversations.
- Introduced conversation-related database models and updated the database schema to support conversation and message storage.
- Implemented chat retention settings, allowing automatic purging of old conversations based on user-defined retention days.
- Enhanced settings management to include ADRE chat retention days, with validation for acceptable values.
- Updated HTTP handlers to support new conversation endpoints and integrated Grafana authentication for user context.

These changes significantly enhance the ADRE functionality, providing users with better management of chat conversations and retention policies.
…nents

- Updated AdreConversation, AdreMessageRow, and AdreSearchHit interfaces to use camelCase for consistency with axios-case-converter.
- Modified Page component to accept a fullWidth prop, allowing for flexible layout adjustments.
- Enhanced AdreChatPanel and AdreConversationsSidebar to support conversation deletion and improved message handling.
- Introduced utility function formatAdreSearchSnippet for cleaner search result display.
- Updated AdrePage to utilize fullWidth layout for better user experience.

These changes improve code consistency, enhance user interface flexibility, and streamline conversation management features.
- Updated AdrePage to include a footer prop for the Page component, enhancing layout flexibility.
- Adjusted Box component styles to set height and maxHeight based on HEADER_HEIGHT, ensuring proper display on various screen sizes.
- Refined styling by adding borderRadius and overflow properties, improving the overall user interface and experience.

These changes enhance the visual consistency and usability of the AdrePage component.
- Updated the AdreMessagesToHolmesHistory function to avoid replaying persisted tool messages in conversation history.
- Added comments to clarify the requirement for tool messages to follow an assistant message, preventing 400 errors from OpenAI and LiteLLM.

These changes enhance the integrity of the conversation history by ensuring proper message sequencing.
- Updated Page, AdrePage, AdreAlertsPanel, and AdreChatPanel components to improve layout consistency and responsiveness.
- Added width, maxWidth, minWidth, and boxSizing properties to ensure proper sizing and overflow handling.
- Refined flex properties and overflow behaviors to enhance user experience and visual clarity.

These changes improve the overall layout and usability of the Adre components, ensuring a more cohesive interface.
…n components

- Updated Providers and MainWithNav components to improve layout structure by incorporating Box components for better flex handling.
- Adjusted styling properties such as flex, minHeight, and overflow to ensure consistent behavior across different screen sizes.
- Enhanced Page component to support flexible padding and gap adjustments based on fullWidth prop, improving overall user experience.

These changes contribute to a more cohesive and responsive interface across the PMM application.
…omponents

- Updated Providers, MainWithNav, Page, AdrePage, and AdreChatPanel components to enhance layout structure and ensure consistent sizing.
- Adjusted flex properties, height, and width settings to improve responsiveness and visual clarity across different screen sizes.
- Enhanced styling to support better alignment and overflow handling, contributing to a more cohesive user experience.

These changes collectively enhance the overall usability and interface consistency of the PMM application.
…d on Grafana page status

- Modified MainWithNav component to include isOnGrafanaPage from useGrafana, allowing for conditional display of the layout.
- Adjusted the display property to 'none' when on a Grafana page, improving the user experience by preventing unnecessary layout rendering.

These changes enhance the responsiveness and usability of the MainWithNav component within the PMM application.
…rail

- Renamed and refactored functions to improve clarity and consistency in handling additional system prompts for chat and QAN insights.
- Introduced `appendScopeGuardrail` to ensure the ScopeGuardrail is appended correctly to prompts, preventing duplication.
- Added comprehensive unit tests to validate the presence and behavior of ScopeGuardrail in default and custom prompts.

These changes improve the robustness and clarity of the prompt handling in the ADRE system, ensuring compliance with the defined ScopeGuardrail.

Signed-off-by: theTibi <tkorocz@gmail.com>
- Replaced the legacy GET /v1/grafana/render endpoint with a new POST /v1/grafana/render/resolve endpoint for improved handling of dashboard rendering requests.
- Introduced a caching mechanism for dashboard JSON data to optimize performance and reduce redundant API calls.
- Updated the README to reflect changes in the rendering API and clarified the usage of new request parameters.
- Added comprehensive unit tests for the new rendering logic and caching behavior to ensure reliability.

These changes enhance the efficiency and clarity of the Grafana rendering process within the PMM application.

Signed-off-by: theTibi <tkorocz@gmail.com>
…atting

- Introduced a new ImageBlock component to render images within investigation reports, supporting various image URL configurations.
- Updated the block export content logic to handle image blocks, ensuring proper rendering of image URLs and associated metadata.
- Enhanced the format report function to include image block data, allowing for seamless integration of images in reports.
- Added sanitization logic for template values to improve data handling and prevent errors in variable processing.

These changes enhance the reporting capabilities of the investigations module by allowing images to be included and displayed correctly.

Signed-off-by: theTibi <tkorocz@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Documentation changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants