mikerhodes commented on issue #2666: soft-deletion for database
URL: https://github.com/apache/couchdb/pull/2666#issuecomment-604431455
 
 
   > Also for the `POST /_deleted_dbs/_undelete` I'll also note that we do have 
a set of system database names that start with an underscore 
(`_dbs/_nodes/_users`). Obviously we don't have an `_undelete` database but it 
is technically mixing that API endpoint into the valid range of database names.
   
   Isn't this the same for adding a `/_undelete_db` into the `/` namespace? In 
both cases you're basically creating a new reserved name in the list of 
databases, although there is certainly a lot of prior art for this in `/` so it 
wouldn't be as surprising and likely to be forgotten later.
   
   While I prefer keeping new `_` endpoints in `/` to a minimum, I can live 
with having a few new endpoints in the `/` namespace. Before we make the final 
call, one additional option which keeps things contained to a single new entry 
in `/` while removing the dbname vs. action ambiguity @davisp mentioned, and 
keeping things somewhat RESTful, would be to extract the `dbs` bit into a 
further sub-namespace:
   
   1.    `GET   /_deleted_dbs/dbs`
   1.    `GET   /_deleted_dbs/dbs/DbName`
   1.    `POST /_deleted_dbs/undelete`
   
   Alternatively you could have `/_deleted/dbs` (etc.) if you wanted to avoid 
the `dbs` repetition, though I feel that `_deleted` is a bit generic for my 
tastes.
   
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to