Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-26 Thread Xuelei Fan
Looks fine to me. Thanks, Xuelei On 8/26/2016 6:51 PM, Svetlana Nikandrova wrote: Ok, it's better to be safe than sorry. Added othervm: http://cr.openjdk.java.net/~snikandrova/8164533/webrev.01/ Thank you, Svetlana On 25.08.2016

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-26 Thread Svetlana Nikandrova
Ok, it's better to be safe than sorry. Added othervm: http://cr.openjdk.java.net/~snikandrova/8164533/webrev.01/ Thank you, Svetlana On 25.08.2016 19:02, Xuelei Fan wrote: Just a quick reply. 1. The close is necessary. 2. Run

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Weijun Wang
On 8/26/2016 2:52, Artem Smotrakov wrote: My point is that it's better to run tests which don't modify the default JSSE configuration in agent VM. It would speed up test execution. Another benefit of this is that if the test still fails it might reveal a real bug. --Max

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Artem Smotrakov
Sure Xuelei, I read https://docs.oracle.com/javase/8/docs/technotes/guides/security/jsse/JSSERefGuide.html#InstallationAndCustomization If I understand correctly, the most settings can be done via system/security properties. But there may be some other ways like setDefaultHostnameVerifier(),

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Xuelei Fan
> On Aug 26, 2016, at 1:33 AM, Artem Smotrakov > wrote: > > Hi Xuelei, > > >> On 08/25/2016 10:26 AM, Xuelei Fan wrote: >> >>> On Aug 26, 2016, at 12:43 AM, Artem Smotrakov >>> wrote: >>> >>> Hi Xuelei, >>> >>> I am not sure why

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Artem Smotrakov
Hi Xuelei, On 08/25/2016 10:26 AM, Xuelei Fan wrote: On Aug 26, 2016, at 12:43 AM, Artem Smotrakov wrote: Hi Xuelei, I am not sure why you think it's too strong to follow to it. To me it's pretty easy to see if a test calls System.setProperty() or

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Xuelei Fan
> On Aug 26, 2016, at 12:43 AM, Artem Smotrakov > wrote: > > Hi Xuelei, > > I am not sure why you think it's too strong to follow to it. To me it's > pretty easy to see if a test calls System.setProperty() or > Security.setProperty() methods which modify default

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Artem Smotrakov
Hi Xuelei, I am not sure why you think it's too strong to follow to it. To me it's pretty easy to see if a test calls System.setProperty() or Security.setProperty() methods which modify default JSSE configuration. Is there any other way to modify default JSSE configuration, so that it can't

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Xuelei Fan
Just a quick reply. 1. The close is necessary. 2. Run in othervm is safer. Please see my comments in other replies. If you still have questions, I will reply with more details tomorrow when I work on a PC. Xuelei > On Aug 25, 2016, at 11:00 PM, Svetlana Nikandrova >

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Svetlana Nikandrova
Hi Artem, Xuelei, thank you for your comments. Please see inline. On 25.08.2016 4:10, Xuelei Fan wrote: On 8/25/2016 3:55 AM, Artem Smotrakov wrote: Hi Svetlana, Thank you for cleaning up this test. I have a couple of comments (mostly about the original test). 1. I see that the test tries

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Xuelei Fan
On 8/25/2016 2:06 PM, Weijun Wang wrote: I think Artem is correct here. All those tests that modify static fields should run in othervm mode, so that *each* runs in its *own* VM. All other tests, which make no such modifications, can share the *same* VM using agentvm. It's too strong to

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-25 Thread Weijun Wang
I think Artem is correct here. All those tests that modify static fields should run in othervm mode, so that *each* runs in its *own* VM. All other tests, which make no such modifications, can share the *same* VM using agentvm. On 8/25/2016 13:31, Xuelei Fan wrote: On 8/25/2016 12:31 PM,

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Xuelei Fan
com To: artem.smotra...@oracle.com Cc: security-dev@openjdk.java.net, svetlana.nikandr...@oracle.com Sent: Wednesday, August 24, 2016 8:20:45 PM GMT -08:00 US/Canada Pacific Subject: Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up th

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Artem Smotrakov
...@oracle.com Cc: security-dev@openjdk.java.net, svetlana.nikandr...@oracle.com Sent: Wednesday, August 24, 2016 8:20:45 PM GMT -08:00 US/Canada Pacific Subject: Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test&quo

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Xuelei Fan
:55 PM GMT -08:00 US/Canada Pacific Subject: Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test" On 8/25/2016 9:27 AM, Artem Smotrakov wrote: BTW, please run the test in othervm mode. Why do you think it's

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Artem Smotrakov
, security-dev@openjdk.java.net Cc: svetlana.nikandr...@oracle.com Sent: Wednesday, August 24, 2016 7:21:55 PM GMT -08:00 US/Canada Pacific Subject: Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test" On 8

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Xuelei Fan
On 8/25/2016 9:27 AM, Artem Smotrakov wrote: BTW, please run the test in othervm mode. Why do you think it's necessary here? I don't see the test modifies anything that may affect other tests running in the same JVM (for example, system properties). Am I missing something? It's not about the

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Artem Smotrakov
Hi Xuelei, Please see inline. On 08/24/2016 06:10 PM, Xuelei Fan wrote: On 8/25/2016 3:55 AM, Artem Smotrakov wrote: Hi Svetlana, Thank you for cleaning up this test. I have a couple of comments (mostly about the original test). 1. I see that the test tries to connect to a server three

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Xuelei Fan
On 8/25/2016 3:55 AM, Artem Smotrakov wrote: Hi Svetlana, Thank you for cleaning up this test. I have a couple of comments (mostly about the original test). 1. I see that the test tries to connect to a server three times, but the server accept only first connection, and then it stops. So

Re: RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Artem Smotrakov
Hi Svetlana, Thank you for cleaning up this test. I have a couple of comments (mostly about the original test). 1. I see that the test tries to connect to a server three times, but the server accept only first connection, and then it stops. So test cases #2-3 fail just because the

RFR 8164533: [TEST_BUG] sun/security/ssl/SSLSocketImpl/CloseSocket.java failed with "Error while cleaning up threads after test"

2016-08-24 Thread Svetlana Nikandrova
Hello, please review this test bug fix. Test failed because of staled threads left after execution. Added try-with-resources statements to make sure test closes it's resources. Also as test is overall quite old-fashioned I've done some refactoring (hope now it looks better). JBS: