GeoServer
  1. GeoServer
  2. GEOS-2609

Geometry sort / regionating , class cast exception when attribute is not a geometry

    Details

    • Type: Bug Bug
    • Status: Open Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 1.7.2
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Number of attachments :
      0

      Description

      If you select regionating strategy: geometry

      But then select a regionating attribute that is not a geometry, the form will let you do so, and the code fails with a class cast exception in
      getSortAttributeValue(SimpleFeature f) , line 74, in GeometryRegionatinStrategy.

      Can we have the UI fail if the attribute is not a geometry, the same way it fails if you do not have a bounding box set ?

      Feel free to assign back to me if you have more important stuff.

        Activity

        Hide
        Arne Kepp added a comment -

        (Sorry, incomplete summary)

        Show
        Arne Kepp added a comment - (Sorry, incomplete summary)
        Hide
        Jukka Rahkonen added a comment -

        I apologize but what is "regionating strategy: geometry"? How to test if this issue is still valid?

        Show
        Jukka Rahkonen added a comment - I apologize but what is "regionating strategy: geometry"? How to test if this issue is still valid?
        Hide
        Arne Kepp added a comment -

        This ticket is about KML hierarchies , where you want to show certain features from very far out and add more placemarks / geometries as you zoom in (aggregating more and more KML tiles client side as you go down). The geometry-based regionating strategy uses the size of the geometry, so big features are visible first.

        So this ticket says it's possible to pick the geometry as a regionating strategy and then choose the column to be a non-geometry.

        (I'm thinking GEOS-2495 is also related to this topic, and kicking myself for not having given more context.)

        Show
        Arne Kepp added a comment - This ticket is about KML hierarchies , where you want to show certain features from very far out and add more placemarks / geometries as you zoom in (aggregating more and more KML tiles client side as you go down). The geometry-based regionating strategy uses the size of the geometry, so big features are visible first. So this ticket says it's possible to pick the geometry as a regionating strategy and then choose the column to be a non-geometry. (I'm thinking GEOS-2495 is also related to this topic, and kicking myself for not having given more context.)
        Hide
        Andrea Aime added a comment -

        Arne, so this would be a GUI/validation bug?

        Show
        Andrea Aime added a comment - Arne, so this would be a GUI/validation bug?
        Hide
        Arne Kepp added a comment - - edited

        Yeah, and it appears to be be possible to do this in 2.6.2, but I didn't find the exception in the logs after trying to view the layer.

        sf:restricted , layer settings , publishing, KML Format Settings
        Set defaul regionating attribute to cat , and default method to geometry.

        Show
        Arne Kepp added a comment - - edited Yeah, and it appears to be be possible to do this in 2.6.2, but I didn't find the exception in the logs after trying to view the layer. sf:restricted , layer settings , publishing, KML Format Settings Set defaul regionating attribute to cat , and default method to geometry.

          People

          • Assignee:
            David Winslow
            Reporter:
            Arne Kepp
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated: