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

Clear image list cache #189

Merged
merged 15 commits into from
Dec 20, 2023
Merged

Clear image list cache #189

merged 15 commits into from
Dec 20, 2023

Conversation

the-last-pastafarian
Copy link
Contributor

No description provided.

Copy link
Member

@dersmon dersmon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like you branched from the project deletion, that is why those changes currently also appear here in the diff (which is between the new branch and master). I ignored that for now.

@@ -4,6 +4,7 @@ defmodule FieldHub.FileStore do
@valid_file_variants Application.compile_env(:field_hub, :valid_file_variants)
@index_cache_name Application.compile_env(:field_hub, :file_index_cache_name)
@index_cache_expiration_ms 1000 * 60 * 60 * 24
# @index_cache_expiration_ms 3000
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What did you try here? This line should probably be deleted at the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I wanted to see what happened without wait one day.

Comment on lines 122 to 123
new_cache = "Delete or update cache in this handle_event"
cache_index = FieldHub.FileStore.file_index(project)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the ticket you do not need to create a new cache, that is already handled by the FileStore internally.

The only thing that has to be triggered from the interface is the FileStore's function to clear the existing cache. If you want to have a look how the file index looks like, you could for example use the Desktop client to push new images into the repository.

@the-last-pastafarian the-last-pastafarian merged commit 0cbefb0 into master Dec 20, 2023
2 checks passed
@dersmon dersmon deleted the clear_image_list_cache branch January 17, 2024 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants