3

GeoServer version 2.18.0 running under Java 1.8.0-131 on a Windows machine.

I am trying to use the GeoServer REST API to seed GeoWebCache. I can get the seed process to commence and can follow its progress using the commands documented. My problem is that I am unable to stop the seeding process once it has started. I have tried the following methods as detailed in the seeding and truncating section of the manual.

  1. Kill the task for a specific layer. POST command of the form :

http://localhost:8080/geoserver/gwc/rest/seed/MYStore:MYLayer

The above line returns 400 - bad request

Various attempts to provide some body for the POST also fail. I have tried JSON of the form { seedRequest : { "name" : "MYStore:MYLayer" }} or the equivalent XML.

  1. Kill all tasks

http://localhost:8080/geoserver/gwc/rest/seed

This returns - Chunk[] is not a valid entry

  1. Using the kill all option as documented (curl attempt shown)
curl -v -u username:password -d "kill_all=all" "http://localhost:8080/geoserver/gwc/rest/seed"

This returns chunk [] is not a valid entry

I have no difficulty kill the seeding task using the GeoServer web interface.

What am I doing wrong?

1 Answer 1

1

Add the workspace & layer to the end of your kill_all command like so:

curl -v -u username:password -d "kill_all=all" "http://localhost:8080/geoserver/gwc/rest/seed/workspace:layername.xml"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.