Codereview request for 6898310: (cs) Charset cache lookups should be synchronized
Ulf Zibis
Ulf.Zibis at gmx.de
Fri Sep 2 13:52:46 UTC 2011
Am 02.09.2011 15:40, schrieb Rémi Forax:
> On 09/02/2011 03:17 PM, Ulf Zibis wrote:
>> Am 02.09.2011 15:00, schrieb Rémi Forax:
>>>
>>> A way to solve the problem is to split AbstractCharsetProvider in two objects
>>> i.e we should create a new object named CharsetProviderView that contains
>>> deleteCharset() and charset() and provide this object as parameter of init.
>>>
>>> The idea is that during the initialization (in init()) calling deleteCharset/charset is safe,
>>> not after.
>>
>> Calling deleteCharset/charset() from init() is completely superfluous.
Oops, deleteCharset/charset() is replaced by (un)register(), so same problem occurs. Soulution could
be to block (un)register() to work, if isCustomized() of afterCustomization() returns true.
-Ulf
>> See my implementation********(Replacement of AbstractCharsetProvider) from
>> *****Bug 100098* <https://bugs.openjdk.java.net/show_bug.cgi?id=100098> - Make sun.nio.cs.*
>> charset objects light-weight**** :
>> https://bugs.openjdk.java.net/attachment.cgi?id=131&action=diff#a/src/share/classes/sun/nio/cs/ExternalCharsetProvider.java_sec1
>>
>
> I agree, you can get ride of init(), but I would prefer to use a static block,
> instead of a properties file.
>
>> -Ulf
>>
>
> Rémi
>
More information about the core-libs-dev
mailing list