JFR.dump sometimes generates jfr recordings that don't respect maxage parameter of StartFlightRecording option.
For example, the attached jfr recording is generated using the following commands:
java -XX:StartFlightRecording=maxage=1m Test
jcmd <pid> JFR.dump name=1 filename=recording.jfr
jfr disassemble --max-chunks 1
Examining recording recording.jfr ...
File consists of 3 chunks. The recording will be split into 3 files
Writing recording_0.jfr ... 1145658
Writing recording_1.jfr ... 1180310
Writing recording_2.jfr ... 957517
jfr summary recording_0.jfr
Start: 2020-09-16 11:06:35 (UTC)
Duration: 41 s
jfr summary recording_1.jfr
Start: 2020-09-16 11:07:17 (UTC)
Duration: 42 s
jfr summary recording_2.jfr
Start: 2020-09-16 11:07:59 (UTC)
Duration: 33 s
Common duration of two latest chunks recording_1 and recording_2 is 75 s, so recording_0 is out of the scope of maxage=1m parameter and it shouldn't be included into the dumped recording.
For example, the attached jfr recording is generated using the following commands:
java -XX:StartFlightRecording=maxage=1m Test
jcmd <pid> JFR.dump name=1 filename=recording.jfr
jfr disassemble --max-chunks 1
Examining recording recording.jfr ...
File consists of 3 chunks. The recording will be split into 3 files
Writing recording_0.jfr ... 1145658
Writing recording_1.jfr ... 1180310
Writing recording_2.jfr ... 957517
jfr summary recording_0.jfr
Start: 2020-09-16 11:06:35 (UTC)
Duration: 41 s
jfr summary recording_1.jfr
Start: 2020-09-16 11:07:17 (UTC)
Duration: 42 s
jfr summary recording_2.jfr
Start: 2020-09-16 11:07:59 (UTC)
Duration: 33 s
Common duration of two latest chunks recording_1 and recording_2 is 75 s, so recording_0 is out of the scope of maxage=1m parameter and it shouldn't be included into the dumped recording.