Skip to content

Commit

Permalink
fix(recordings): uploaded archives should be viewable with Grafana (#541
Browse files Browse the repository at this point in the history
)

Signed-off-by: Thuan Vo <[email protected]>
  • Loading branch information
tthvo authored Jun 28, 2024
1 parent c5ea2a3 commit 727d14b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/main/java/io/cryostat/recordings/Recordings.java
Original file line number Diff line number Diff line change
Expand Up @@ -805,7 +805,12 @@ public Uni<String> uploadActiveToGrafana(@RestPath long targetId, @RestPath long
@RolesAllowed("write")
public Response uploadArchivedToGrafanaBeta(
@RestPath String connectUrl, @RestPath String filename) throws Exception {
var jvmId = Target.getTargetByConnectUrl(URI.create(connectUrl)).jvmId;
String jvmId;
if ("uploads".equals(connectUrl)) {
jvmId = "uploads";
} else {
jvmId = Target.getTargetByConnectUrl(URI.create(connectUrl)).jvmId;
}
return Response.status(RestResponse.Status.PERMANENT_REDIRECT)
.location(
URI.create(
Expand Down

0 comments on commit 727d14b

Please sign in to comment.