Do not append to file when size of m_dic is only one and new key is the same with that one in m_dic #1150
Closed
kaitian521
started this conversation in
Ideas
Replies: 1 comment 2 replies
-
This could work, but only in SINGLE_PROCESS_MODE. In multi-process mode, MMKV relys on the fact that m_actualSize will increase whenever there's update made by others. Checkout |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In some circumstances, I store only one key in MMKV.
For example, I put user's latest edit content to MMKV, giving me a chance to restore them for next startup of My App
At present, key-value will be appended to the file, then a rewrite will be called when being full
I think maybe there is a very small improvement for this:
Thank you !
Beta Was this translation helpful? Give feedback.
All reactions