Jesse Eichar wrote: > Hi, > > I want to make some optimizations to some of the Spatial Filters so > that we can get some significant (10-20x) performance improvements. > However the implementations are all read/write. I have three options > and I wanted feedback on how others thought I should proceed. > > 1. Make the spatial filters read only so I don't have to worry about > it anymore. We can discuss how to do this at a later date. > Currently they are only read/write via the old GeoTools interfaces (where setLeftGeometry() and so on are available). You will find some code is already caching values (and thus considering at least the literals) to be read only. > 2. Make a parallel implementation of the filters that are readonly. > That would be fine as well; it would be nice to have a clean set of filter implementations to test with. > 3. Tough it out and add these optimizations to the read/write filters > We can check in with Andrea about the filter migration work he was doing; you may be able to remove the set methods now. > The reason this is an issue is because the strategy involves caching > some information (like prepared geometries). It is pretty trivial if > the objects are read-only and I can do the calculation at setup. But > if they are read/write then I have to worry about how to re-create the > cached information. > See above; some literal information is already being cached. > The other side is that if I make things readonly then I have to be > able to figure out what objects use the read/write behaviour and > update them. That is where the parallel set of filters comes in. I > can have a hint so that a different filter factory is created that > returns read-only objects. > Cheers, Jody
------------------------------------------------------------------------------ _______________________________________________ Geotools-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-devel
