I think I've discovered a bug in 2.6.1 but I need a second opinion. I
upgraded to 2.6.1 from 2.2.5 so as far as I know the issue could have been
introduced anywhere in between.
I have a line layer in Oracle Locator 11gR2 with around 100,000 features
(all 2-vertex lines, no line strings). Rendering a map showing an area
within the layer, containing perhaps 500 features, is nice and fast - maybe
two seconds. However, a getFeatureInfo operation with the same parameters
(bbox, style, cql_filter etc.) is extremely slow - over two minutes. The
issue was originally observed in a custom application but I /can/ replicate
it in the OpenLayers layer preview.
I enabled verbose logging and did some digging. The issue appears to come
from the SQL query that GeoServer sends to Oracle. In 2.2.5 getMap and
getFeatureInfo, and 2.6.1 getMap, the spatial part of the query looks like
this:
SELECT ... FROM ... WHERE (SDO_FILTER(LINE,
MDSYS.SDO_GEOMETRY(2003,4326,NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,3),MDSYS.SDO_ORDINATE_ARRAY(<minx>,<miny>,<maxx>,<maxy>)),
'mask=anyinteract querytype=WINDOW') = 'TRUE'
However, in 2.6.1 getFeatureInfo the spatial part looks like this:
SELECT ... FROM ... WHERE (SDO_FILTER(LINE,
MDSYS.SDO_GEOMETRY(2003,4326,NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,3),MDSYS.SDO_ORDINATE_ARRAY(<minx>,<miny>,<maxx>,<maxy>)),
'mask=anyinteract querytype=WINDOW') = 'TRUE' *OR* (SDO_FILTER(LINE,
MDSYS.SDO_GEOMETRY(2003,4326,NULL,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,3),MDSYS.SDO_ORDINATE_ARRAY(<minx>,<miny>,<maxx>,<maxy>)),
'mask=anyinteract querytype=WINDOW') = 'TRUE'
Presumably the severe slowdown comes from both clauses trying to do the same
thing simultaneously. Perhaps if my line layer had fewer features I wouldn't
even notice that this was an issue.
Does this look like something that warrants a new bug report?
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Possible-getFeatureInfo-bug-in-2-6-1-tp5179690.html
Sent from the GeoServer - User mailing list archive at Nabble.com.