Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix local storage and content removal #125

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

elyesbenamor
Copy link

Closes #121
Closes #115
Closes #96
Closes #28

Changes Made

  1. Fixed file handling logic in store_file method:
  • store_local: true with retention - files are kept locally for the specified duration
  • S3 upload functionality - files are properly uploaded and stored
  • Verified configuration parsing for boolean values and retention settings
  1. Improved configuration handling:

    • Fixed boolean parsing to handle YAML native boolean values correctly
    • Moved media_retention settings outside the config block
    • Added proper defaults when configuration values are not set
  2. Added retention features:

    • Implemented remote_media_lifetime functionality to delete files from S3 after specified duration
    • Files are kept indefinitely in S3 if remote_media_lifetime is not set
    • Added scheduled deletion using reactor.callLater for both local and remote files
  3. Enhanced logging:

    • Added detailed logging for file operations
    • Improved error messages for failed uploads and deletions
    • Added logging for retention scheduling

Documentation

  • Updated README with clearer examples and explanations of retention settings
  • Added documentation for the remote_media_lifetime feature

@elyesbenamor elyesbenamor requested a review from a team as a code owner January 23, 2025 21:26
@elyesbenamor
Copy link
Author

@reivilibre

@drallgood
Copy link

Those look like useful fixes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants