Auto-Deletion Problem with files-retention - when tagging folders and files with different invisible tags

Hello!

I have a problem with the “Retention App”, when tagging folders and files with different (invisible) tags, the auto-deletion feature, for the files, don’t work as expected.

Background: I’d like to delete the files on a regular base, but won’t like to destroy the folder structure underneath.

My Setup

NC Version 14.0.3 (running on CentOS7 with PostgresDB)
App: file-retention Version 1.3.0
Background jobs: Cron

Files automated tagging

  • Rule 1 - No-Retention
  • no_retention_tag (invisible)
    File MIME type IS httpd/unix-directory
  • Rule 2
  • retention_tag (invisible)
    File MIME type IS NOT httpd/unix-directory

File retention

  • retention_tag (invisible): 1 days

Check1:
Folders and Files were tagged with the correct tags, when uploaded or manually made.

  • Files: retentions_tag
  • Folders: no-retention_tag

Check2:
Folders aren’t deleted after 1 day - correct, works like expected!
Files aren’t deleted automatically after 1 day - incorrect, they should be deleted after 1 day (= File Retention Policy)

Can anyone comprehend this behaviour?
Any ideas how I can get fix this?

Thanks in advance!

Greetz
Bernhard

Addendum:
Today the files were deleted (like expected yesterday) but I had to wait one day longer then expected.
Therefore, I assume that the “file retention time” is not checked in “real time” and probes only in full calendar days (24h, day change).

i also tryied this for all documents but it only works for manualy tagging .
is there any way when a documents gets uploaded autmatically gets a retention policy?

Hi Hobe,

You use automatic tagging and file retention ?

Hello @hber57,

yes, we are using automatic tagging and file retention in our nextcloud installation. How can I help you? What would you like to know about?

Hello Hobe,

To delete files with files automated tagging, you used Rule 2 with File MIME condition ? correct ?
You defined this tage on folder ?

Thanks,

Hello @hber57,

Thats the way I have setup the “Files automated tagging” in Nextcloud, to automatically delete files but preserve the folder structure underneath:

  • Rule 1 - No-Retention *

  • no_retention_tag (invisible)
    File MIME type IS httpd/unix-directory
    -> This tags the FOLDERS only, to give them a exclusive special tag

  • Rule 2 - Retention

  • retention_tag (invisible)
    File MIME type IS NOT httpd/unix-directory
    -> This tags the FILES (= all other MIME-Types then httpd/unix-directory) only

File retention

  • retention_tag (invisible) : 1 days
    -> This deletes all files (tagged with ‘retention_tag’) after the given time (24h Intervall)

Hope this will help you!

Greetz
Bernhard

Hi,

Thanks you Bernhard, i will test.