actinia-org / actinia-core

Actinia Core is an open source REST API for scalable, distributed, high performance processing of geographical data that uses mainly GRASS GIS for computational tasks (DOI: https://doi.org/10.5281/zenodo.5879231) | Tutorial: https://actinia-org.github.io/actinia-core/ | Docker: https://hub.docker.com/r/mundialis/actinia-core
https://actinia.mundialis.de/
GNU General Public License v3.0
78 stars 23 forks source link

Mapset Locking behaves not as expected when mapset doesn't exist #487

Open mmacata opened 10 months ago

mmacata commented 10 months ago

The POST endpoint to create a mapset lock returns 400: curl -u XX -X POST "http://127.0.0.1:8088/api/v3/locations/nc_spm_08/mapsets/test_mapset_2/lock"

AsyncProcessError: Unable to lock mapset <test_mapset_2>. Mapset doesn not exists. If the mapset doesn't exit. That seems about right but the lock is created nevertheless: "RESOURCE-LOCK::group/nc_spm_08/test_mapset_2" inside the redis database.

Now a mapset with this name cannot be created (because it is locked), it cannot be removed (because it doesn't exist) and the lock cannot be removed as well (because the mapset doesn't exist).

This should behave more intuitive.