[ckan-discuss] Complete deletion of a resource

Stéphane Guidoin stephane at opennorth.ca
Fri Aug 23 01:17:52 BST 2013


Hello,

*Short version*: Is there a way to fully delete an uploaded resource so
that even the file cannot be accessed anymore?

*Long version*: From what I can see (CKAN 2.0), deleting an uploaded
resource via the web admin (or re-upload the same file) does not delete the
file. It just makes that the web page of the resource link the new
resource. But if someone, for a reason or another, has a direct link to the
file, that person might continue to propagate the "deleted" file.

Example: I create a ressource:
http://my.ckan.ca/storage/f/2013-08-15T1*9%3A06%3A01.344Z*/resource.csv

for a reason or another, I need to replace that resource or delete it. For
example, I try to reupload it. The new resource linked on the CKAN page is
now
http://my.ckan.ca/storage/f/2013-08-15T*20%3A22%3A64.765Z*/resource.csv
But the old one
(http://my.ckan.ca/storage/f/2013-08-15T1*9%3A06%3A01.344Z*/resource.csv)
is still accessible for someone who would have kept the URL or using it.
Obviously, we would prefer a good old 404...

The obvious case is for a file who would have some errors and where you
absolutely want that nobody uses that file, the current delete or reupload
will not make it. The only option I see is to manually erase the file in
the DB which is something we would like to avoid because it is obviously a
risky business to directly manipulate the DB content.

So, did I miss something? Is there a way to completely erase a resource?

Thank you

Stéphane
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-discuss/attachments/20130822/a8e99f7a/attachment.htm>


More information about the ckan-discuss mailing list