Changes between Version 4 and Version 5 of rfc16_ogr_reentrancy
- Timestamp:
- Sep 4, 2007, 9:08:09 AM (17 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
rfc16_ogr_reentrancy
v4 v5 44 44 This class has been modified to include an m_hMutex class data member which is a mutex used to ensure thread safe access to internal datastructures such as the layer list. Classes derived from OGRDataSource that wish to implement threadsafe operation should use this mutex when exclusivity is required. 45 45 46 == ExecuteSQL() == 46 47 48 The default OGR implementation of OGRDataSource::ExecuteSQL() internally uses and modifies the layer state (feature iterators and filters) and as such is not appropriate to use on a datasource that is attempting to be threadsafe even though it is understood that individual layers are not threadsafe. The proposed solution is to offer an OGRTS "dialect" (OGR Thread Safe) which actually opens a duplicate (readonly) datasource so that there will be distinct instances of the layers for the use of the resulset from ExecuteSQL(). This is very expensive in terms of file access and file handles consumed so it is not the default. The default dialect (NULL, "" or "OGR") will continue to use the layers from the current datasource despite the various side effects implied. 49 50 51