Summary
Remove jdk.jfr.Recording::setFlushInterval/duration), jdk.jfr.Recording::getFlushInterval() and jdk.jfr.RecordingStream::setFlushInterval that was introduced with JEP 349: JFR Event Streaming.
Problem
Purpose of the setFlushInterval(Duration) and getFlusInterval() methods was to control the rate at which data are flushed to disk. A higher flush rate means less overhead.
After integration integration of the JEP, the conclusion is that the overhead using a value of 1 s is not measurable and the methods don't carry weight to be part of the API.
Solution
Remove or make methods package private so they are not exposed in the API.
Specification
Class: jdk.jfr.Recording:
- public void setFlushInterval(Duration interval) {
+ /* package private */ void setFlushInterval(Duration interval) {
- public Duration getFlushInterval() {
+ /* package private */ Duration getFlushInterval() {
Class: jdk.jfr.consumer.RecordingStream
- /**
- * Determines how often events are made available for streaming.
- *
- * @param interval the interval at which events are made available to the
- * stream, no {@code null}
- *
- * @throws IllegalArgumentException if {@code interval} is negative
- *
- * @throws IllegalStateException if the stream is closed
- */
- public void setFlushInterval(Duration interval) {
- recording.setFlushInterval(interval);
- }
- csr of
-
JDK-8236264 Remove jdk.jfr.Recording::setFlushInterval and jdk.jfr.Recording::getFlushInterval
-
- Resolved
-