[mapguide-trac] #1538: Speed up Coordinate System Dictionary lookup
when reading all CS definitions at one
MapGuide Open Source
trac_mapguide at osgeo.org
Thu Nov 25 15:44:28 EST 2010
#1538: Speed up Coordinate System Dictionary lookup when reading all CS
definitions at one
---------------------------+------------------------------------------------
Reporter: baertelchen | Owner: baertelchen
Type: enhancement | Status: new
Priority: low | Milestone: 2.3
Component: General | Version: 2.1.0
Severity: minor | Keywords: Coordinate System API
External_id: |
---------------------------+------------------------------------------------
When reading all available coordinate system definitions from the
dictionary (in this case, from coordsys.csd), the current implementation
does (way too) many file look ups via CsMap. For each(!) CS definition to
be read (out of thousands), the implementation will first read the CS'
name (1), this name is later taken to read the CS' definition (2). When
creating the MgCoordinateSystem instance, the CS' datum is taken and the
MgCsDatum instance is created(3). While creating the MgCsDatum instance,
the MgEllipsoid instance is also created (4).
The numbers indicate the file accesses via CsMap. This includes a global
in-process lock, the file access itself inside CsMap (which does a divide-
and-conquer-like search within the file) and the construction of the
object.
This ticket is to fix the implementation of
[MgCoordinateSystemEnum::Next(UINT32 ulCount)] in
[CoordSysEnum::Next(UINT32 ulCount)] as returned by the
[CoordSysDictionary] class.
That is, when an API client is about to read ALL available systems (as
indicated by the UINT32 ulCount parameter), the lookup has to be much
faster.
--
Ticket URL: <http://trac.osgeo.org/mapguide/ticket/1538>
MapGuide Open Source <http://mapguide.osgeo.org/>
MapGuide Open Source Internals
More information about the mapguide-trac
mailing list