azavea / python-sld

A simple python library that enables dynamic SLD creation and manipulation.
http://azavea.github.com/python-sld/
Apache License 2.0
27 stars 17 forks source link

StyledLayerDescriptor not safe for multiple processes #8

Closed MikeTheReader closed 6 years ago

MikeTheReader commented 11 years ago

I have a project where I need to load multiple layers. To speed up this process, I'm launching multiple processes to retrieve the layer images. If there are multiple layers that have SLD's associated with them, they can break sometimes when there is contention over the schema document created within the init method of StyledLayerDescriptor. Is there a known workaround for this situation?

I'm looking at modifying the code locally to just keep the schema file around at all times to prevent this contention, but wanted to see if there were other ways of dealing with it.

Thanks much.