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

Replace StorageManager with StorageFilesProvider #8677

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

cketti
Copy link
Member

@cketti cketti commented Dec 15, 2024

StorageManager was used to support storing the message database (and attachments) either on internal or external storage. We removed the ability to use anything but internal storage a while ago.

This change moves the remaining functionality from StorageManager to StorageFilesProviderFactory and StorageFilesProvider. This also allows us to remove K9MessageStore's dependency on the account UUID.

@cketti cketti requested a review from wmontwe as a code owner December 15, 2024 23:51
@wmontwe wmontwe self-assigned this Jan 6, 2025
Copy link
Member

@wmontwe wmontwe left a comment

Choose a reason for hiding this comment

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

Overall I like the change to remove the UUID dependency and split it up into provider and factory patterns. I just think that the names could be adjusted to better reflect their purpose.


import java.io.File

interface DatabaseFilesProvider {
Copy link
Member

Choose a reason for hiding this comment

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

I think that StorageFilesProvider is more accurate as it provides the database file and attachment folder.

Copy link
Member Author

Choose a reason for hiding this comment

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

Done

@cketti cketti force-pushed the remove_StorageManager branch from decf6b6 to e268b6b Compare January 10, 2025 19:48
@cketti cketti changed the title Replace StorageManager with DatabaseFilesProvider Replace StorageManager with StorageFilesProvider Jan 10, 2025
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