Best practice for things and not-logged in users

Hey bubblers,
I am quite a beginner and there is a problem I can’t come up with a solution right now:

  1. At the moment not-logged in users can create audio recordings.
  2. Those are saved in a thing called “audio”
  3. At the moment, when I am working with an “audio” I am doing a search with “:latest”

Now this leads to two problems:

  1. But I am pretty sure, this is going to blow up as soon as more than one user uses the app.
  2. My filemanager will get flooded with MP3 files nobody is using in the future

So my question is:

  1. How can I handle the files and URLs when I don’t want the user to login - everything should work without loggin in

  2. How can I get rid of unused files after a user is done?

Eager to learn some best practices!

Thanks everbody
Dennis

What do you mean by this - what are you trying to do?

  1. How can I get rid of unused files after a user is done?

You mean you want to delete the files?

Hey Adam,
thanks for replying :slight_smile:

The user can upload his voice and will get a transcript with whisper. In the end the transcript is put through Chatgpt for an analyzis. The user get’s the first analyzis for free and in-depth is supposed to cost money.

But to make the “entry barrier” as low as possible, I want to make it without the necessity to create an account and log in.

Yes, maybe after X days of creation.

I will try to save the “working data” into the user object. This solves problem #1.

Can I delete a lot of files at once in the file manager based on date and file type?

I imagine creating a “Cron”-Job like behaviour to clean the files.

No, only based on URL and only one at at time unless run through a recursive workflow.

Please help the cause and upvote the idea to delete a list of files