Ian,
this is even more confusing.
It does indeed work through the REST api when I change the SvgParameter
lines to CssParameter.
But when I upload the file with SvgParameters from within the GeoServer,
it is accepted, and I can see all SvgParameter lines in the style editor.
Is there a reason why the REST api behaves differently?
Serge.
Ian Turton schreef op 17/10/2013 15:04:
It is removing the non conformant bits when it processes the style.
All the SvgParameter should be CSSParameter.
Ian
On 17 October 2013 12:24, Serge de Schaetzen <serg...@gmail.com
<mailto:serg...@gmail.com>> wrote:
Hello,
I have a weird problem when uploading an SLD file to geoserver 2.4.0
using the RESP api.
The style gets uploaded successfully (http 200 is returned), and I can
see it in the list of styles in the geoserver admin gui.
But, parts of the style have been removed.
I've embedded the style I upload as well as what I see on the
geoserver
adming gui.
You can see that all lines starting with <sld:SvgParameter.. have
disappeared.
Any idea?
Serge
SLD that gets uploaded:
------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<sld:StyledLayerDescriptor xmlns="http://www.opengis.net/sld"
xmlns:ogc="http://www.opengis.net/ogc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sld="http://www.opengis.net/sld" version="1.1.0"
xsi:schemaLocation="http://www.opengis.net/sld
http://schemas.opengis.net/sld/1.1.0/StyledLayerDescriptor.xsd">
<NamedLayer>
<sld:Name>line</sld:Name>
<UserStyle>
<sld:Name>line</sld:Name>
<sld:FeatureTypeStyle>
<sld:Rule>
<sld:Name>Single symbol</sld:Name>
<sld:LineSymbolizer>
<sld:Stroke>
<sld:SvgParameter
name="stroke">#FF0000</sld:SvgParameter>
<sld:SvgParameter
name="stroke-width">3.26</sld:SvgParameter>
<sld:SvgParameter
name="stroke-linejoin">bevel</sld:SvgParameter>
<sld:SvgParameter
name="stroke-linecap">square</sld:SvgParameter>
<sld:SvgParameter name="stroke-dasharray">5
2</sld:SvgParameter>
</sld:Stroke>
</sld:LineSymbolizer>
<sld:LineSymbolizer>
<sld:Stroke>
<sld:SvgParameter
name="stroke">#00FF00</sld:SvgParameter>
<sld:SvgParameter
name="stroke-width">2.26</sld:SvgParameter>
<sld:SvgParameter
name="stroke-linejoin">round</sld:SvgParameter>
<sld:SvgParameter
name="stroke-linecap">square</sld:SvgParameter>
<sld:SvgParameter name="stroke-dasharray">5
2</sld:SvgParameter>
</sld:Stroke>
</sld:LineSymbolizer>
</sld:Rule>
</sld:FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</sld:StyledLayerDescriptor>
Tomcat Logfile:
---------------------
... 88 more
17 Oct 12:27:20 DEBUG [org.geotools.styling] -
StyleLayerDescriptorImpl
added 1 styled layers
17 Oct 12:27:20 DEBUG [org.geotools.styling] - number of fts set 1
17 Oct 12:27:26 DEBUG [org.geotools.styling] - number of fts set 1
17 Oct 12:27:26 INFO [org.geoserver.catalog.rest] - PUT style line
Style at the GeoServer GUI:
--------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<sld:StyledLayerDescriptor xmlns="http://www.opengis.net/sld"
xmlns:sld="http://www.opengis.net/sld"
xmlns:ogc="http://www.opengis.net/ogc"
xmlns:gml="http://www.opengis.net/gml" version="1.0.0">
<sld:NamedLayer>
<sld:Name>line</sld:Name>
<sld:UserStyle>
<sld:Name>line</sld:Name>
<sld:FeatureTypeStyle>
<sld:Name>name</sld:Name>
<sld:Rule>
<sld:Name>Single symbol</sld:Name>
<sld:LineSymbolizer>
<sld:Stroke/>
</sld:LineSymbolizer>
<sld:LineSymbolizer>
<sld:Stroke/>
</sld:LineSymbolizer>
</sld:Rule>
</sld:FeatureTypeStyle>
</sld:UserStyle>
</sld:NamedLayer>
</sld:StyledLayerDescriptor>
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get
the most from
the latest Intel processors and coprocessors. See abstracts and
register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135031&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
<mailto:Geoserver-users@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/geoserver-users
--
Ian Turton
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135031&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users