cryostatio / cryostat

Other
7 stars 8 forks source link

[Bug] Uploaded archives cannot be viewed in Grafana #540

Closed tthvo closed 5 days ago

tthvo commented 6 days ago

Current Behavior

Uploaded archives (i.e. using the upload modal in Archives view, or direct API) cannot be be viewed on Grafana. The error returns with status code 404.

Expected Behavior

Uploaded archive should be able to be loaded and viewed on Grafana Dashboard.

Steps To Reproduce

  1. Deploy the Cryostat application using the k8s operator (latest main or cryostat-v3 branch): https://github.com/cryostatio/cryostat-operator. Or just local smoketest with docker-compose.
  2. Obtain any JFR file (i.e. start and archive recording or elsewhere)
  3. Upload the JFR file using the UI. The action should succeed with the archive showing up.
  4. Click on the 3-dot icon on the far-right on the archive and select View in Grafana....
  5. Observe the notification to show an error with status 404

Environment

- OS: Fedora 40
- Minikube version: v1.32.0 (k8s v1.28.3)
- Cryostat Operator Version: v4.0.0-dev

Anything else?

The connectUrl being used in this case is uploads. Should it be handled separately without checking with database? Perhaps, jvmId = "uploads" instead?

https://github.com/cryostatio/cryostat/blob/c5ea2a3440e9e6080a8fe81dcb5a7883d99020dc/src/main/java/io/cryostat/recordings/Recordings.java#L806-L816