Closed mangalaman93 closed 6 years ago
Maximum size of Arena
< total system memory
/ 4 so that we leave some memory for OS and ensure that we can keep 2 Arenas in memory for the queue.
Whether Persist | Update Allowed | Max Value | Min Value | |
---|---|---|---|---|
Maximum Size of Arena | yes | no | Maximum Size of Arena < Total System Memory / 4 | OS Page Size |
Maximum Memory Used by BigQueue | No | yes | Total System Memory | 2 * Arena Size |
GC frequency | No | yes | - | - |
We should use a
Config
object to allow configuring BigQueue. We should allow a useful default value for each configuration as well as ensure that configurations are set correctly using possible checks around each parameter. We should allow creating bigqueue without the config object using the default values.Here is the list of configuration parameters -
2 * Size of Arena
)We will have to persist the configuration parameters so that we can read these parameters back across different invocation of same application.
I still think that we should keep the directory as an argument to
NewBigQueue
to ensure an explicit invocation of creating a queue using a path. Given that path is what defines a BigQueue, the expectation will be set properly in that if you lose the directory, you lose the queue