GeoServer
  1. GeoServer
  2. GEOS-607

SLD files not deleted with SLD is deleted in web admin

    Details

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

      Description

      The SLD files stored on the server need to be deleted when the user deletes the SLD from the web admin tool. Right now the file isn't deleted, and if I remove and then add the SLD back (with changes or something), you get it saying that you cannot use that file because a file with the same name already exists.

        Issue Links

          Activity

          Chris Holmes made changes -
          Field Original Value New Value
          Fix Version/s 1.6.x [ 13213 ]
          Fix Version/s 1.5.x [ 11705 ]
          Gabriel Roldan made changes -
          Assignee Brent Owens [ bowens ] Gabriel Roldán [ groldan ]
          Hide
          Andrea Aime added a comment -

          In 2.0.x I think we could actually delete the sld since we don't have the apply/save dance. Justin, are we doing so already?

          Show
          Andrea Aime added a comment - In 2.0.x I think we could actually delete the sld since we don't have the apply/save dance. Justin, are we doing so already?
          Andrea Aime made changes -
          Link This issue is duplicated by GEOS-1743 [ GEOS-1743 ]
          Hide
          Justin Deoliveira added a comment -

          No we are not, some users have complained about this behavior. The best middle ground I can see is instead of deleting the old file move it to a ".bak" or something.

          Show
          Justin Deoliveira added a comment - No we are not, some users have complained about this behavior. The best middle ground I can see is instead of deleting the old file move it to a ".bak" or something.
          Andrea Aime made changes -
          Fix Version/s 1.6.x [ 13213 ]
          Hide
          Ragi Burhum added a comment -

          I am using the REST Geoserver API and I am also running into this. It is somewhat difficult to deal with this when the HTTP DELETE with purge=true leaves the file dangling. Help?

          Show
          Ragi Burhum added a comment - I am using the REST Geoserver API and I am also running into this. It is somewhat difficult to deal with this when the HTTP DELETE with purge=true leaves the file dangling. Help?
          Hide
          Justin Deoliveira added a comment -

          Hmmm... a style DELETE with purge=true should have deleted the underlying file... if not it is a bug. What version of geoserver are we talking here? And what is the entire request?

          Show
          Justin Deoliveira added a comment - Hmmm... a style DELETE with purge=true should have deleted the underlying file... if not it is a bug. What version of geoserver are we talking here? And what is the entire request?
          Hide
          Ragi Burhum added a comment -

          Running latest stable (2.1.3)

          If you delete the style from the admin, it doesn't purge. Then if you try to create a style using the same name using the REST API (POST), it complains that it already exists (even though it does not). If you try to call the REST DELETE to get it to go away, it complains that it cannot find it.

          Doing everything purely from the REST API with purge=true works fine, however the moment somebody interacts with the admin to delete styles, all bets are off.

          Show
          Ragi Burhum added a comment - Running latest stable (2.1.3) If you delete the style from the admin, it doesn't purge. Then if you try to create a style using the same name using the REST API (POST), it complains that it already exists (even though it does not). If you try to call the REST DELETE to get it to go away, it complains that it cannot find it. Doing everything purely from the REST API with purge=true works fine, however the moment somebody interacts with the admin to delete styles, all bets are off.
          Hide
          Justin Deoliveira added a comment -

          Thanks Ragi, makes sense. I imagine we could add another "remove link" to the style page, something "remove and purge". Should't be too much work. Care to submit a patch?

          Show
          Justin Deoliveira added a comment - Thanks Ragi, makes sense. I imagine we could add another "remove link" to the style page, something "remove and purge". Should't be too much work. Care to submit a patch?
          Hide
          Ragi Burhum added a comment -

          I can try. I don't know java, but I can probably figure it out. Any hint on which files I should be looking at?

          Show
          Ragi Burhum added a comment - I can try. I don't know java, but I can probably figure it out. Any hint on which files I should be looking at?

            People

            • Assignee:
              Gabriel Roldan
              Reporter:
              Brent Owens
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: