expose mdb_env_set_flags()
mikedilger opened this issue · comments
During migrations, I want to set NO_SYNC | NO_META_SYNC.
(yes I try to do it as one transaction anyways)
Isn't the EnvOpenOptions::flag
method not enough? It is available on the 0.20.0-alpha versions.
So do I open a separate env? And can I do that while I still have another env already open (I open the env originally in a lazy static)? and then it seems I'd have to open all the database again too. Lots of calls to use EnvOpenOptions.
Could you describe what you would like to do? If I had to open an env with specific options, I would use the EnvOpenOptions
to set up the flags and use it the whole program. Are you trying to change the environment options when the env is already opened? If so, you could close it with the Env::prepare_for_closing
method and reopen it afterward.
I'm no longer doing this. I was opening it without these options and syncing every transaction, then during certain sequences I wanted it to not sync every transaction. Now I'm manually handling the syncing.