jakarta-regexp-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 34548] - RE constructor is not thread safe
Date Fri, 22 Apr 2005 05:13:03 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=34548>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34548





------- Additional Comments From james.cherryh@defence.gov.au  2005-04-22 07:13 -------
OK, I've read the comments in the RE header and I see there that they note the
class is not threadsafe. Obviously whoever implemented the code here didn't know
that. We're using the RE constructors in code running in an app server, so we
can get concurrent threads of execution trying to create an RE at the same time.
We've worked around it by introducing a synchronised wrapper as in the test case
I included.

I'd suggest that many people wouldn't have realised that RE isn't threadsafe. We
propose a new class REThreadsafe which simply wraps the RE constructors in a
threadsafe way. That way developer's attention would be drawn to the issue and
they could use the threadsafe constructors if they have a multi-threaded context
and correctness is more important than performance :-)

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

---------------------------------------------------------------------
To unsubscribe, e-mail: regexp-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: regexp-dev-help@jakarta.apache.org


Mime
View raw message