When the planner runs, it needs to determine if any files have tombstones. The code to determine if a tombstone existed involved stating the .tombstone file. Since the planner runs very frequently when there are many shards, this causea a lot of system calls that are unnecessary. Instead, cache the results of the stats calls and only refresh them when we haven't checked at least once or we write new tombstone data. This also caches the results of the TSMReader.Stats call to avoid creating garbage. |
||
---|---|---|
.. | ||
tsm1 | ||
engine.go |