[Geoserver-devel] [jira] Created: (GEOS-1420) Current interpretation of SLD library mode does not conform to the spec (afaik)

Current interpretation of SLD library mode does not conform to the spec (afaik)
-------------------------------------------------------------------------------

                 Key: GEOS-1420
                 URL: http://jira.codehaus.org/browse/GEOS-1420
             Project: GeoServer
          Issue Type: Bug
          Components: WMS
    Affects Versions: 1.6.0-beta3
            Reporter: Andrea Aime
            Assignee: Andrea Aime
             Fix For: 1.6.0-RC1

Current code in GetMapKvpRequestReader.processSld interprets the sld layer mode in this way:
if any layer parameter is provided along with sld or sld_body, then for each layer name a style is looked up
in the sld document whose name equals to the layer name.

This is, in my opinion, incosistent with what the SLD 1.0 spec says:
page 23, 8. User defined styles:
"The Name, Title and Abstract elements allow a user-defined style to be identified and
are optional. The given Name is equivalent to the name of a WMS named style and is
used to reference the style externally when an SLD is used in 'library mode' (Section 6.4)
and identifies the named style to redefine when an SLD is inserted into a WMS
(Section 13)."

page 7:
"To make the HTTP-GET methods more practical for use, the SLD can also be used in
one of two different modes depending on whether the LAYERS parameter is present in the
request. If it is not present, then all layers identified in the SLD document are rendered
with all defined styles, which is equivalent to the XML-POST method of usage. If the
LAYERS parameter is present, then only the layers identified by that parameter are
rendered and the SLD is used as a "style library".

When an SLD is used as a style library, the STYLES CGI parameter is interpreted in the
usual way in the GetMap request, except that the handling of the style names is organized
so that the styles defined in the SLD take precedence over the named styles stored within
the map server. The user-defined SLD styles can be given names and they can be marked
as being the default style for a layer. To be more specific, if a style named
"CenterLine" is referenced for a layer and a style with that name is defined for the
corresponding layer in the SLD, then the SLD style definition is used. Otherwise, the
standard named-style mechanism built into the map server is used. If the use of a default
style is specified and a style is marked as being the default for the corresponding layer in
the SLD, then the default style from the SLD is used; otherwise, the standard default style
in the map server is used."

The spec says to use the styles paramer to lookup the styes, not the layers one.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira