cryostatio / cryostat-web

Web front-end for Cryostat: Secure JDK Flight Recorder management for containerized JVMs
https://cryostat.io/
Other
10 stars 20 forks source link

chore(mbeans): adjust MBeanMetrics GraphQL query for updated schema #1219

Closed andrewazores closed 6 months ago

andrewazores commented 6 months ago

Welcome to Cryostat! 👋

Before contributing, make sure you have:

To recreate commits with GPG signature git fetch upstream && git rebase --force --gpg-sign upstream/main


Depends on https://github.com/cryostatio/cryostat3/pull/307 Based on #1218

Description of the change:

Adjusts GraphQL queries for the updated schema in 3.0 where the mbeanMetrics subquery is nested under the Target object, not under the TargetNode (the DiscoveryNode which the Target belongs to). Adjusts the client's data model to always expect labels and annotations on Targets returned from the API, whether GraphQL or plain HTTP, and for both labels and annotations to use the new "key-value list" format.

Motivation for the change:

Restores the web UI's ability to retrieve MBean Metrics for the Dashboard and Topology, as seen in the screenshot below.

How to manually test:

  1. Run CRYOSTAT_IMAGE=quay.io... sh smoketest.sh...
  2. ...

image

github-actions[bot] commented 6 months ago

This PR/issue depends on:

andrewazores commented 6 months ago

/build_test

github-actions[bot] commented 6 months ago

Test image available:

CRYOSTAT_IMAGE=ghcr.io/cryostatio/cryostat-web:pr-1219-a37abbbbc1d1c339103ae1fdfc8426e115808ca1 bash smoketest.bash # then open http://localhost:8080
andrewazores commented 6 months ago

Not sure why the diff here is including https://github.com/cryostatio/cryostat-web/pull/1216 as part of the commit set. That's already merged into main which this is based on top of, but I guess something about the unmerged upstream cryostat3-graphql branch is confusing GitHub's UI.