JDK-6964018 : AnonLoggerWeakRefLeak and LoggerWeakRefLeak can fail in JPRT
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util.logging
  • Affected Version: 7,7u25
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2010-06-24
  • Updated: 2013-09-12
  • Resolved: 2011-03-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7 Other
7 b105Fixed OpenJDK6Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Description
Alan B. reported the following tests can fail in a JPRT job:

    java/util/logging/AnonLoggerWeakRefLeak.sh
    java/util/logging/LoggerWeakRefLeak.sh

Here are snippets from the JPRT logs:

> --------------------------------------------------
> TEST: java/util/logging/AnonLoggerWeakRefLeak.sh
> JDK under test: (C:\temp\jprt\T1\T\072215~1.AB2\TESTPR~1\WINDOW~1.2-P)
> java version "1.7.0-201006240722.ab23780.jdk"
> Java(TM) SE Runtime Environment (build 1.7.0-201006240722.ab23780.jdk-jprtadm_2010_06_24_00_34-b00)
> Java HotSpot(TM) 64-Bit Server VM (build 19.0-b02, mixed mode)
>
>
> ACTION: build -- Passed. Build successful
> REASON: User specified action: run build AnonLoggerWeakRefLeak TIME:   0.047 seconds
> messages:
> command: build AnonLoggerWeakRefLeak
> reason: User specified action: run build AnonLoggerWeakRefLeak elapsed time (seconds): 0.047
>
> ACTION: compile -- Passed. Compilation successful
> REASON: .class file out of date or does not exist
> TIME:   0.031 seconds
> messages:
> command: compile C:\temp\jprt\T1\T\072215.ab23780\source\test\java\util\logging\AnonLoggerWeakRefLeak.java
> reason: .class file out of date or does not exist
> elapsed time (seconds): 0.031
>
> ACTION: shell -- Failed. Execution failed: exit code 1
> REASON: User specified action: run shell/timeout=180 AnonLoggerWeakRefLeak.sh TIME:   62.342 seconds
> messages:
> command: shell AnonLoggerWeakRefLeak.sh []
> reason: User specified action: run shell/timeout=180 AnonLoggerWeakRefLeak.sh elapsed time (seconds): 62.342
> STDOUT:
> INFO: starting AnonLoggerWeakRefLeak as pid = 3016
> INFO: killing 3016
> STDERR:
> ERROR: AnonLoggerWeakRefLeak failed to get going.
> kill: C:\temp\jprt\T1\T\072215.ab23780\source\test\java\util\logging\AnonLoggerWeakRefLeak.sh 140: 3016: no such process
>
> TEST RESULT: Failed. Execution failed: exit code 1
> --------------------------------------------------
>   

and

> --------------------------------------------------
> TEST: java/util/logging/LoggerWeakRefLeak.sh
> JDK under test: (C:\temp\jprt\T1\T\072215~1.AB2\TESTPR~1\WINDOW~1.2-P)
> java version "1.7.0-201006240722.ab23780.jdk"
> Java(TM) SE Runtime Environment (build 1.7.0-201006240722.ab23780.jdk-jprtadm_2010_06_24_00_34-b00)
> Java HotSpot(TM) 64-Bit Server VM (build 19.0-b02, mixed mode)
>
>
> ACTION: build -- Passed. Build successful
> REASON: User specified action: run build LoggerWeakRefLeak TIME:   0.047 seconds
> messages:
> command: build LoggerWeakRefLeak
> reason: User specified action: run build LoggerWeakRefLeak elapsed time (seconds): 0.047
>
> ACTION: compile -- Passed. Compilation successful
> REASON: .class file out of date or does not exist
> TIME:   0.047 seconds
> messages:
> command: compile C:\temp\jprt\T1\T\072215.ab23780\source\test\java\util\logging\LoggerWeakRefLeak.java
> reason: .class file out of date or does not exist
> elapsed time (seconds): 0.047
>
> ACTION: shell -- Failed. Execution failed: exit code 1
> REASON: User specified action: run shell/timeout=240 LoggerWeakRefLeak.sh TIME:   61.311 seconds
> messages:
> command: shell LoggerWeakRefLeak.sh []
> reason: User specified action: run shell/timeout=240 LoggerWeakRefLeak.sh elapsed time (seconds): 61.311
> STDOUT:
> INFO: starting LoggerWeakRefLeak as pid = 4604
> INFO: killing 4604
> STDERR:
> ERROR: LoggerWeakRefLeak failed to get going.
>
> TEST RESULT: Failed. Execution failed: exit code 1
> --------------------------------------------------
>   


The Solaris-SPARCv9 failures

> --------------------------------------------------
> TEST: java/util/logging/AnonLoggerWeakRefLeak.sh
> JDK under test: (/tmp/jprt/T1/T/072215.ab23780/testproduct/solaris_sparcv9_5.10-product)
> java version "1.7.0-201006240722.ab23780.jdk"
> Java(TM) SE Runtime Environment (build 1.7.0-201006240722.ab23780.jdk-jprtadm_2010_06_24_00_36-b00)
> Java HotSpot(TM) 64-Bit Server VM (build 19.0-b02, mixed mode)
>
> ACTION: build -- Passed. Build successful
> REASON: User specified action: run build AnonLoggerWeakRefLeak TIME:   0.025 seconds
> messages:
> command: build AnonLoggerWeakRefLeak
> reason: User specified action: run build AnonLoggerWeakRefLeak elapsed time (seconds): 0.025
>
> ACTION: compile -- Passed. Compilation successful
> REASON: .class file out of date or does not exist
> TIME:   0.023 seconds
> messages:
> command: compile /tmp/jprt/T1/T/072215.ab23780/source/test/java/util/logging/AnonLoggerWeakRefLeak.java
> reason: .class file out of date or does not exist
> elapsed time (seconds): 0.023
>
> ACTION: shell -- Failed. Execution failed: exit code 2
> REASON: User specified action: run shell/timeout=180 AnonLoggerWeakRefLeak.sh TIME:   8.465 seconds
> messages:
> command: shell AnonLoggerWeakRefLeak.sh []
> reason: User specified action: run shell/timeout=180 AnonLoggerWeakRefLeak.sh elapsed time (seconds): 8.465
> STDOUT:
> INFO: starting AnonLoggerWeakRefLeak as pid = 19559
> INFO: jmap exited with exit code = 1
> INFO: on the first iteration so no samples were taken.
> INFO: start of jmap output:
> 19559: Unable to open door: target process not responding or HotSpot VM not loaded
> The -F option can be used when the target process is not responding
> INFO: end of jmap output.
> INFO: killing 19559
> STDERR:
> FAIL: jmap is unable to take any samples.
>
> TEST RESULT: Failed. Execution failed: exit code 2
>   --------------------------------------------------
>   

and

--------------------------------------------------
TEST: java/util/logging/LoggerWeakRefLeak.sh
JDK under test: (/tmp/jprt/T1/T/072215.ab23780/testproduct/solaris_sparcv9_5.10-product)
java version "1.7.0-201006240722.ab23780.jdk"
Java(TM) SE Runtime Environment (build 1.7.0-201006240722.ab23780.jdk-jprtadm_2010_06_24_00_36-b00)
Java HotSpot(TM) 64-Bit Server VM (build 19.0-b02, mixed mode)

ACTION: build -- Passed. Build successful
REASON: User specified action: run build LoggerWeakRefLeak
TIME:   0.025 seconds
messages:
command: build LoggerWeakRefLeak
reason: User specified action: run build LoggerWeakRefLeak
elapsed time (seconds): 0.025

ACTION: compile -- Passed. Compilation successful
REASON: .class file out of date or does not exist
TIME:   0.024 seconds
messages:
command: compile /tmp/jprt/T1/T/072215.ab23780/source/test/java/util/logging/LoggerWeakRefLeak.java
reason: .class file out of date or does not exist
elapsed time (seconds): 0.024

ACTION: shell -- Failed. Execution failed: exit code 2
REASON: User specified action: run shell/timeout=240 LoggerWeakRefLeak.sh
TIME:   8.446 seconds
messages:
command: shell LoggerWeakRefLeak.sh []
reason: User specified action: run shell/timeout=240 LoggerWeakRefLeak.sh
elapsed time (seconds): 8.446
STDOUT:
INFO: starting LoggerWeakRefLeak as pid = 19572
INFO: jmap exited with exit code = 1
INFO: on the first iteration so no samples were taken.
INFO: start of jmap output:
19572: Unable to open door: target process not responding or HotSpot VM not loaded
The -F option can be used when the target process is not responding
INFO: end of jmap output.
INFO: killing 19572
STDERR:
FAIL: jmap is unable to take any samples.

TEST RESULT: Failed. Execution failed: exit code 2
--------------------------------------------------

Comments
EVALUATION http://hg.openjdk.java.net/jdk6/jdk6/jdk/rev/ac4185bdf1b2
26-07-2010

EVALUATION http://hg.openjdk.java.net/jdk7/tl/jdk/rev/9cb77130999f
22-07-2010

EVALUATION Drop use of TESTVMOPTS (for now) to prevent mismatch between VMs on Solaris. It is not clear why the other platforms don't have this problem with TESTVMOPTS. Adjust PID searching logic for MKS. Update: Refactor to use both Java and shell infrastructure in test/sun/tools/common.
20-07-2010

SUGGESTED FIX See attached 6964018-webrev-cr0.tgz file for the proposed fix.
20-07-2010