Hi Semyon,
I had verified the patch fix with Windows 7 64-bit, Ubuntu 14.04 32 & 64 bit & Mac platform. Where the test executes & passes. Are you using Ubuntu 15.10 ? I am setting up Ubuntu 15.10 64 bit to reproduce the same failure. However, solution to this failure would require a small wait for gc to finish. Regards, Ambarish From: Semyon Sadetsky Sent: Wednesday, December 02, 2015 1:54 PM To: Ambarish Rapte; Prasanta Sadhukhan; [email protected] Subject: Re: Review Request for 8039081: [TEST_BUG] Test java/awt/TrayIcon/PopupMenuLeakTest/PopupMenuLeakTest.java fails Hi Ambarish, Now it fails on Linux: ACTION: main -- Failed. Execution failed: `main' threw exception: java.lang.OutOfMemoryError: Java heap space REASON: User specified action: run main/othervm -Xmx50m PopupMenuLeakTest TIME: 1.445 seconds messages: command: main -Xmx50m PopupMenuLeakTest reason: User specified action: run main/othervm -Xmx50m PopupMenuLeakTest elapsed time (seconds): 1.445 STDOUT: STDERR: java.lang.OutOfMemoryError: Java heap space at PopupMenuLeakTest.assertCollected(PopupMenuLeakTest.java:85) at PopupMenuLeakTest.main(PopupMenuLeakTest.java:57) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:520) at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:92) at java.lang.Thread.run(Thread.java:747) JavaTest Message: Test threw exception: java.lang.OutOfMemoryError: Java heap space JavaTest Message: shutting down test STATUS:Failed.`main' threw exception: java.lang.OutOfMemoryError: Java heap space --Semyon On 11/30/2015 6:44 PM, Ambarish Rapte wrote: Hi Semyon, I have updated the fix patch with below changes, 1. Code formatting. 2. Reduced the number of OOMs. 3. Removed un-required delays. Please review the update patch, which causes OOM early than previous change. HYPERLINK "http://cr.openjdk.java.net/%7Earapte/8039081/webrev.01/"http://cr.openjdk.java.net/~arapte/8039081/webrev.01/ Thanks, Ambarish From: Semyon Sadetsky Sent: Monday, November 30, 2015 1:54 PM To: Ambarish Rapte; Prasanta Sadhukhan; HYPERLINK "mailto:[email protected]"[email protected] Subject: Re: Review Request for 8039081: [TEST_BUG] Test java/awt/TrayIcon/PopupMenuLeakTest/PopupMenuLeakTest.java fails Hi Ambarish, On my Windows 7 64bit the test fails because of timeout. --Semyon On 11/20/2015 1:30 PM, Ambarish Rapte wrote: Hi All, Please review the fix for JDK9, Bug: https://bugs.openjdk.java.net/browse/JDK-8039081 Webrev: http://cr.openjdk.java.net/~arapte/8039081/webrev.00/ Issue: è The test fails on windows with below exception, Caused by: java.lang.IllegalArgumentException: illegal popup menu container class at sun.awt.windows.WPopupMenuPeer.<init>(WPopupMenuPeer.java:65) at sun.awt.windows.WToolkit.createPopupMenu(WToolkit.java:461) at java.awt.PopupMenu.addNotify(PopupMenu.java:124) at PopupMenuLeakTest.addNotifyPopup(PopupMenuLeakTest.java:63) è With below exception on mac, ubuntu, java.lang.OutOfMemoryError: Java heap space at PopupMenuLeakTest.assertCollected(PopupMenuLeakTest.java:85) at PopupMenuLeakTest.main(PopupMenuLeakTest.java:57) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:520) at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:92) at java.lang.Thread.run(Thread.java:747) Cause: This is a test code issue. On Windows Popup menu should have a valid parent container. Is there is no parent container , then above exception is thrown. And also, after throwing OOM exception, program tried to allocate new memory in catch. Which results in failure again. Fix: Updated the test code to add popup menu as a child of Frame. Verifiew on : Ubuntu, Windows & Mac Many Thanks, Ambarish
