Hi

After investigating some transient slowness in Mapfish Print (a webapp that
uses GeoTools V11.0) I've found out that for each and every GML it is
parsing, it is downloading the XSDs from external web sites. For example
[1].

That causes us several problems:

   1. Very very slow if the web site serving the XSD is totally swamped.
   The other day, fetching this resource was taking an average of 50s.
   2. Slow because fetching stuff the other side of the world is never as
   fast as locally. Today's RTT with [1] is 124ms.
   3. Doesn't work if the machine running GeoTools doesn't have web access.

I've checked the code of GeoTools and looks like there is a class for
caching XSDs and even using a resource files instead: SchemaResolver [2].
But this guy is not used when parsing GML.

I've checked the master branch of GeoTools and this problem seems to be
still there. I've checked GeoServer and looks like they have not a very
different usage of the Parser class.

Our code can be found on github in [3].

So, how do I fix all that? I need to be able to have some XSDs stored in
the project resources and I need to have some caching of the other schemas.

Thanks for your help.

[1] http://schemas.opengis.net/wfs/1.1.0/wfs.xsd

[2]
http://docs.geotools.org/latest/javadocs/org/geotools/xml/resolver/SchemaResolver.html#getSimpleHttpResourcePath-java.net.URI-

[3]
https://github.com/mapfish/mapfish-print/blob/master/core/src/main/java/org/mapfish/print/map/geotools/GmlLayer.java#L186
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
GeoTools-Devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to