-
Notifications
You must be signed in to change notification settings - Fork 0
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
#108-implement-soft-delete-mechanism-for-media #115
base: dev
Are you sure you want to change the base?
Conversation
…default delay 0.2s
…rofile services, one prepare image to add and update, second delete profile image. Image formats are in jpeg format only in minio. But accepts all images standards
…ad app processes and create simple add_task method to delay image remove by 30min
…ded to cloud storage minio
backend/src/common/utils.py
Outdated
logger = logging.getLogger(__name__) | ||
|
||
|
||
def delay_time(time_string="0.2s"): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should add docstring there
def delayed_task(): | ||
if delay: | ||
delay_time(delay) | ||
func(*args, **kwargs) | ||
|
||
make_thread(delayed_task) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if we add a new feature and we need to rebuild our server? The delay will disappear. We need to save the timestamp of deletion and check it in a separate task. This is my idea.
Signed-off-by: MaciejKan <[email protected]>
No description provided.