-
Notifications
You must be signed in to change notification settings - Fork 78
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
Support for extending database size? #39
Comments
Well, I would agree with you that such scenario is not well supported. Possible strategies:
|
Just for my education, why can't we simply extend? If I understand everything is an offset within a contiguous block of memory, adding new offsets beyond the first block would spill over into the 2nd block that's allocated on the demand. It's acceptable to keep allocating new blocks which can be then linked so that one block handles a set of offsets, right? I am also considering whether it's acceptable to dump database, resize, load. The only concern is whether this will cause excessive pause between resizes. |
AFAIK we don't have enough control over how the shared memory is mapped into the virtual address space. There should be contiguous unused address space available to fit all the segments and future segments for that idea to work. Some platforms do not even let you control where your segment is mapped. |
Ah, gotcha. My scenario actually was for a local database; I do not need it in the shared memory. Would that make a difference? |
As I understand it, WhiteDB require that
size
parameter be provided when creating/loading the database. This doesn't work well in scenarios where the size isn't known in advance and could vary considerably.If it's not practical to implement extending an open database's memory space, what strategies are available for allocating more memory on demand in a performant manner?
The text was updated successfully, but these errors were encountered: