RFR 9: [testbug] 8168613 : CORBA ObjectStreamTest fails with address in use

Roger Riggs Roger.Riggs at Oracle.com
Tue Oct 25 20:50:25 UTC 2016


Hi,

On 10/25/2016 4:31 PM, Paul Sandoz wrote:
> Hi Roger,
>
> Do you need to use a double-checked locking idiom in getEchoStub?
Probably not, I'm  just practicing the idiom.
We are unlikely to move to concurrent test execution in testng (when it 
supports it).
>
> I cannot recall the life-cycle of per test execution, but i suspect you might be able to turn the static field and method getEchoStub into a non-static field and just make the method synchronized, but you might ned to annotate the shutdown with @AfterClass instead.
That would work too.

What's the rule for choosing synchronized vs volatile?  I've gotten 
different recommendations in different cases.
What's Occam's razor here?
>
> Actually, perhaps even better initiate the ORB and create the stub in a @BeforeClass method and clean up in a @AfterClass method?
that would work, but it is only used in one of the tests.  So just 
trying to keep the usage localized.

Thanks, Roger

>
> Paul.
>
>> On 25 Oct 2016, at 12:51, Roger Riggs <Roger.Riggs at Oracle.com> wrote:
>>
>> Please review a test fix for an address-in-use problem in this CORBA serialization test.
>> The test is simplified to just communicate client to server via the orb in the process.
>>
>> It does not need activation, a name service, or the orbd to exercise the
>> necessary serialization implementation.  And therefore, no contention for sockets, ports, etc.
>>
>> Webrev:
>>    http://cr.openjdk.java.net/~rriggs/webrev-orb-addrinuse-8168613/
>>
>> Thanks, Roger
>>



More information about the core-libs-dev mailing list