RFR: 8257424: Add setName() to RecordingStream
Erik Gahlin
egahlin at openjdk.java.net
Tue Dec 1 01:57:55 UTC 2020
On Tue, 1 Dec 2020 00:19:45 GMT, Yasumasa Suenaga <ysuenaga at openjdk.org> wrote:
> `RemoteRecordingStream` would set the specified recording name.
> https://github.com/openjdk/jdk/blob/master/src/jdk.management.jfr/share/classes/jdk/management/jfr/RemoteRecordingStream.java#L278
>
> > The underlying recording is an implementation detail, not sure it should show up in jcmd at all.
>
> If so, why `RemoteRecordingStream` will set the name?
>
> > Also, RemoteRecordingStream and RecordingStream should be interchangeable and setting the name on RemoteRecordingStream will not work with the current implementation.
>
> I think we can add `setName()` to both `RecordingStream` and `RemoteRecordingStream`, and also it is nature because `RemoteRecordingStream` will set specified name in current behavior.
The name is used to identify if it is a streaming recording, so it is closed properly. See OngoingStream. This is no ideal solution, but it works for now.
-------------
PR: https://git.openjdk.java.net/jdk/pull/1520
More information about the hotspot-jfr-dev
mailing list