RFR: 8257234 : Add gz option to SA jmap to write a gzipped heap dump [v9]
Chris Plummer
cjplummer at openjdk.java.net
Tue Jan 26 04:44:45 UTC 2021
On Tue, 26 Jan 2021 04:40:19 GMT, Chris Plummer <cjplummer at openjdk.org> wrote:
>> Sorry for typo. the GzipAccess should be GzipRandomAccess.
>
> So the problem is that the code in GzipRandomAccess.getAccess() returns NULL if it doesn't find the "HPROF BLOCKSIZE" comment, but you are also saying that tools like heaphero.io work fine without the comment. So maybe you just need to fix GzipRandomAccess.getAccess() to use a default blocksize if none is specified.
>
> On the other hand, it seems it would be best if the SA hprof file was no different than the jcmd hprof file, and the SA file also included the comment. But as you said GZIPOutputStream() does not support adding a comment in the same manner as the zlib library does. I'm not sure how you would go about adding the support, so probably it is not worth it.
As for any testing requirement, maybe you could pass in a flag to Reader indicating whether or not the testing requires the "HPROF BLOCKSIZE" comment.
-------------
PR: https://git.openjdk.java.net/jdk/pull/1712
More information about the serviceability-dev
mailing list