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

Does object created from MMDB_open further detect mmdb file updates? #322

Closed
nezdolik opened this issue Oct 16, 2023 · 2 comments
Closed

Comments

@nezdolik
Copy link

Hi, whenever an mmdb file used by a process has been initialized with MMDB_open call and the file has been modified in process, would those changes be detected for mmdb object? Or does one need to watch file for update events and to reload mmdb object with MMDB_open call on update event?

@nezdolik nezdolik changed the title Does MMDB_open watches for file changes? Does object created from MMDB_open further detect mmdb file updates? Oct 16, 2023
@oschwald
Copy link
Member

No, it does not watch the file for changes. The application would need to watch if it wants hot-reloads of files.

If you are updating the the file while the application is running, I would recommend writing the file atomically so that the old file handle remains valid when the file is updated.

@nezdolik
Copy link
Author

Thanks @oschwald!

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

No branches or pull requests

2 participants