RFR: JDK-8059586: hs_err report should treat redirected core pattern.
david.holmes at oracle.com
Tue Dec 9 08:56:50 UTC 2014
So can we take this as-is for now and file a RFE to address your concerns?
Anybody else object to that?
On 9/12/2014 6:09 PM, Thomas Stüfe wrote:
> Hi David,
> On Tue, Dec 9, 2014 at 6:39 AM, David Holmes <david.holmes at oracle.com
> <mailto:david.holmes at oracle.com>> wrote:
> Hi Thomas,
> On 8/12/2014 8:27 PM, Thomas Stüfe wrote:
> I do not really like the handling of the leading pipe symbol:
> To be fair to Yasumasa this aspect of the fix has been the same
> since Oct 15:
> and was not flagged.
> You are right, I did not read those mails close enough.
> So, we read the core_pattern, and if the pipe symbol is detected, we
> write the core pattern minus the pipe symbol but plus a leading
> quote to
> the output; the leading quote then serves as a info to the layer
> in os_posix.cpp to treat this case specially. This means the logic
> spills out of the platform dependend os_linux.cpp to shared code and
> this is also difficult to read.
> This comes from the fact that "get_core_path()" assumes the core
> file is
> written to the file system. I think it just does not fit
> anymore, better
> would be to replace it with something like
> "os::print_core_file_location(__outputStream* os)", and the OS
> both core path retrieval and the printing. Because then the
> shared code
> does not need to know whether core file gets printed
> traditionally or
> piped to a executable or whatever.
> This sounds like a refactoring that I suggested would be too disruptive.
> I do not think that this would be such a big a change, but it also could
> be done with another patch.
> Apart from my reservations I stated above the code looks fine and is
> definitly an improvement (just last week I was helplessly looking for a
> core on a machine where core_pattern turned out to be a redirection to
> another program).
> Kind Regards, Thomas
More information about the hotspot-runtime-dev