As far as I know, XStream should not be involved in updating an SLD file.  I
guess you uploaded with a Content-type of text/xml instead of
application/vnd.ogc.sld+xml (or so, I forget the exact mime for SLD).  It's
troubling that the previous style would be overwritten in this case,
however.

You could also try bumping the logging level up to GEOSERVER_DEVELOPER or so
and see if any more illuminating information appears.

--
David Winslow
OpenGeo - http://opengeo.org/

On Thu, Nov 18, 2010 at 11:11 AM, David Zwarg
<dzwarg...@azavea.com<dzwarg%2...@azavea.com>
> wrote:

> Hello,
>
> I am using the REST config to add some layers and styles to geoserver. All
> is well when creating layers and styles. I've been following the examples
> and using the API reference, which are extremely helpful.
>
> I am running into a problem, though, with uploading SLDs. I am able to POST
> to /geoserver/rest/styles, and create a new style, but when I PUT to
> /geoserver/rest/styles/new_style with my file, I get an HTTP status of 500.
> I look in catalina.out and see:
>
> com.thoughtworks.xstream.mapper.CannotResolveClassException:
> StyledLayerDescriptor : StyledLayerDescriptor
> ...
>
> So I figured my style wasn't uploaded. Incorrect! It did load, and is now
> displayed when I pull up the style in the admin section. Then I thought,
> maybe it just won't validate because it's formatted incorrectly. Incorrect
> again! The style validates in the admin interface.
>
> What am I doing wrong here?
> Thanks,
> David
>
>
> ------------------------------------------------------------------------------
> Beautiful is writing same markup. Internet Explorer 9 supports
> standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
> Spend less time writing and  rewriting code and more time creating great
> experiences on the web. Be a part of the beta today
> http://p.sf.net/sfu/msIE9-sfdev2dev
> _______________________________________________
> Geoserver-users mailing list
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
>
------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today
http://p.sf.net/sfu/msIE9-sfdev2dev
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to