*** 10,15 **** --- 10,23 ---- ---- + *Background merges* + + If we were storing segments outside sqlite, then one solution for merging would be to run the merge in the background, while the foreground continues to use the old segments for queries. When the merge is complete, a transaction could update the segment dir, then the old data could be deleted. While the work done is the same, the merge is removed from blocking anything (always assuming it doesn't starve anyone for shared CPU or disk or memory resources). + + I haven't been able to think of a way to phrase this within the sqlite database, but perhaps there's a way. + + ---- + *Developer influence on segment merges* Right now, segment merges are always forced events. So while the average might be a couple hundred inserts per second, that average includes some inserts which themselves take many seconds. That kind of variance isn't really acceptable.