Skip to content

Change base location for the LevelDB directory #844

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

Closed
wants to merge 1 commit into from

Conversation

DiogoAndre
Copy link

Proposing a change in the location where the LevelDB files are stored on iOS.

Today the base directory is Documents/ and I'm proposing we change it to Library/Application support

Fixes #843

@googlebot
Copy link

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for the commit author(s). If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and have the pull request author add another comment and the bot will run again. If the bot doesn't comment, it means it doesn't think anything has changed.

@DiogoAndre
Copy link
Author

Updated CLA

@wilhuff wilhuff self-assigned this Feb 23, 2018
@wilhuff
Copy link
Contributor

wilhuff commented Feb 23, 2018

Thanks for bringing this up and thanks for the PR! I'll discuss this with the team today.

A problem with this in its current form is that it causes users with Firestore on a device to lose their data. In particular any writes pending synchronization would be lost.

The way to handle this and make things better going forward would be move any existing database from Documents to Application Support but that's not as easy to do as this small change, in part because our tests rely on being able to specify the directory that leveldb will use.

The trouble is we've set things up to delay all real work into start to avoid blocking the main thread during startup but we specify which directory to use to the initializer. This will need some rearranging to make it possible for start to consider both the legacy location and the new.

@morganchen12
Copy link
Contributor

Closing this since this was resolved in #4609.

@firebase firebase locked and limited conversation to collaborators Mar 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New Location for the LevelDB directory
4 participants