Open silviucpp opened 7 years ago
I'll check it... but please keep in mind that tts
is queue time-to-sync (rotate) file segments in milliseconds. I would not keep it equal to 0.
ohh ok :) thanks
Right, I've checked your case deeply. Actually, 0
is not valid value for tts
and capacity
. The capacity
defines the size of in-memory queue. The queue would not fetch anything from disk into memory buffer if capacity is 0
. You should not afraid to put capacity > 0
. The queue always writes data to disk during enqueue.
I would do the following improvements
capacity
only if it is > 0
tts
only if it is > 0
@fogfish you can also add documentation for capacity
in the readme
Hello,
Having the following queue:
After I add few items inside the queue and restart the app and do:
I always receive
undefined
but esq:deq always returns items. I'm expecting head to return same stuff as deq but without removing the item from queue.I'm using
[{tts, 0}, {capacity, 0}]
to make sure all items are going on the disk directly. I'm wrong ?Silviu