I've been looking to see what it the easiest way to get KML into
GeoServer, and I wanted to check to see if the best option is still to
use ogr to first convert the KML into another format that GeoServer
currently handles and then import that? I see that there are options to
output KML (http://geoserver.org/display/GEOS/KML+Support), and the last
posts on this topic were in 2009 so I'm not sure if the ogr route was
still the only/best option. And if it is, there is no way to capture
any styling in the KML file into a SLD (or otherwise get it into
GeoServer), correct?
Thanks in advance,
David Carnes
On Wed, May 29, 2013 at 4:16 AM, David Carnes <dcarnes@anonymised.com> wrote:
I've been looking to see what it the easiest way to get KML into
GeoServer, and I wanted to check to see if the best option is still to
use ogr to first convert the KML into another format that GeoServer
currently handles and then import that?
Yes, that's the best way. XML based format make for a really poor input
source,
they cannot be indexed and are slow to read compared to shapefiles and
spatial databases.
I see that there are options to
output KML (http://geoserver.org/display/GEOS/KML+Support), and the last
posts on this topic were in 2009 so I'm not sure if the ogr route was
still the only/best option. And if it is, there is no way to capture
any styling in the KML file into a SLD (or otherwise get it into
GeoServer), correct?
Nope, in GeoServer data and style are separated, there is no way to mix
them.
That said, if someone was interested and had enough resources to spend on
this,
it would be possible to both upgrade the GeoTools data model to support
"per feature" styles
and create a data store that can read XML files from disk, including KML
ones
Cheers
Andrea
--
GeoServer training in Milan, 6th & 7th June 2013! Visit
http://geoserver.geo-solutions.it for more information.
Ing. Andrea Aime
@geowolf
Technical Lead
GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
-------------------------------------------------------