-
Enhancement
-
Resolution: Unresolved
-
P4
-
None
-
None
-
None
At the moment, the IRecordingDescriptor.RecordingState enum [0] differs from the RecordingState enum in jdk.jfr [1]. As a result, doing a comparison between the two enums is not always a happy path, as seen in https://github.com/cryostatio/cryostat-core/issues/313
Perhaps this was an old enum from when JFR was proprietary? Could this just be substituted with jdk.jfr.RecordingState?
There's also a static method in RecordingDescriptorV2 decideState() that returns a RecordingState [2], it would be nice if it was updated and also publicly available.
[0]https://github.com/openjdk/jmc/blob/master/application/org.openjdk.jmc.rjmx.services.jfr/src/main/java/org/openjdk/jmc/rjmx/services/jfr/IRecordingDescriptor.java#L49
[1] https://docs.oracle.com/en/java/javase/17/docs/api/jdk.jfr/jdk/jfr/RecordingState.html
[2] https://github.com/openjdk/jmc/blob/9fc022ba22caba27fa6b7b1066dba01d23a33792/application/org.openjdk.jmc.rjmx.services.jfr/src/main/java/org/openjdk/jmc/rjmx/services/jfr/internal/RecordingDescriptorV2.java#L91