santuario-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 44991] Concurrent invocation of KeyInfo. getX509Certificate() occasionally fails
Date Sun, 18 May 2008 20:15:15 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=44991





--- Comment #3 from Giedrius Noreikis <giedrius.noreikis@gmail.com>  2008-05-18 13:15:15
PST ---
Created an attachment (id=21978)
 --> (https://issues.apache.org/bugzilla/attachment.cgi?id=21978)
KeyResolverVector

Yes, copying just a *reference* to the *same* object changes nothing - returned
list must be a copy of the *object*, which will not be affected by the
subsequent updates.

Reproducing this bug is not easy (nevertheless, it appears in our production
from time to time). I create 100 threads, each sleeps random time before
proceeding, and repeat the procedure 100 times. Almost always it fails at some
iteration.

In case you are interested in my solution, I attach the files (I couldn't wait
any longer, 'cause I had to fix this bug in our system). I decided to introduce
a new class - KeyResolverVector - to encapsulate the shared resource and the
synchronized methods for accessing it. Of course, KeyResolver and KeyInfo had
to be adjusted accordingly.

Regards,
Giedrius


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

Mime
View raw message