[Biojava-dev] Thread safety question

Keith James kdj at sanger.ac.uk
Thu Sep 11 06:41:14 EDT 2003


>>>>> "Thomas" == Thomas Down <thomas at derkholm.net> writes:

[...]

    Thomas> I seem to remember that it's possible to fix this by
    Thomas> declaring the relevant field volatile -- is this true?

Yes, I saw this mentioned. Apparently it will only work under certain
circumstances:

http://www.javaworld.com/javaworld/jw-02-2001/jw-0209-double-p2.html

It appears that the only cast-iron approach is to synchronize the
operation.

cheers,

Keith

-- 

- Keith James <kdj at sanger.ac.uk> Microarray Facility, Team 65 -
- The Wellcome Trust Sanger Institute, Hinxton, Cambridge, UK -


More information about the biojava-dev mailing list