You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2001/11/21 21:16:51 UTC

DO NOT REPLY [Bug 5008] New: - GenericeDataSource.getConnection not thread safe

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=5008>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=5008

GenericeDataSource.getConnection not thread safe

           Summary: GenericeDataSource.getConnection not thread safe
           Product: Struts
           Version: 1.0 Final
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Minor
          Priority: Other
         Component: Utilities
        AssignedTo: struts-dev@jakarta.apache.org
        ReportedBy: philip0530@yahoo.com


If multiple threads are started that access a virgin GenericDataSource with the
getConnection method it is possible to have more than one thread invoking
open(). This can result in several threads failing because of errors thrown in
the jdbc driver.

The code segment:

if (driver == null)
	open();

should be made thread safe.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>