Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
tthvo opened this issue Jun 28, 2024 · 0 comments · Fixed by #541
Closed

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

tthvo opened this issue Jun 28, 2024 · 0 comments · Fixed by #541
Assignees
Labels
bug Something isn't working

Comments

@tthvo
Copy link
Member

tthvo commented Jun 28, 2024

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?

public Response uploadArchivedToGrafanaBeta(
@RestPath String connectUrl, @RestPath String filename) throws Exception {
var jvmId = Target.getTargetByConnectUrl(URI.create(connectUrl)).jvmId;
return Response.status(RestResponse.Status.PERMANENT_REDIRECT)
.location(
URI.create(
String.format(
"/api/v3/grafana/%s",
recordingHelper.encodedKey(jvmId, filename))))
.build();
}

@tthvo tthvo added bug Something isn't working needs-triage Needs thorough attention from code reviewers and removed needs-triage Needs thorough attention from code reviewers labels Jun 28, 2024
@tthvo tthvo moved this to Todo in 3.0.0 release Jun 28, 2024
@tthvo tthvo self-assigned this Jun 28, 2024
@tthvo tthvo moved this to In progress in 4.0.0 release Jun 28, 2024
@tthvo tthvo moved this from Todo to In Progress in 3.0.0 release Jun 28, 2024
@github-project-automation github-project-automation bot moved this from In Progress to Done in 3.0.0 release Jun 28, 2024
@github-project-automation github-project-automation bot moved this from In progress to Done in 4.0.0 release Jun 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant