add throttling to dagstore; increase GC frequency to 1min.

This commit is contained in:
Raúl Kripalani 2021-07-27 15:11:49 +01:00
parent 160fab08aa
commit 18f5997d02

View File

@ -609,10 +609,12 @@ func DagStoreWrapper(
} }
cfg := dagstore.MarketDAGStoreConfig{ cfg := dagstore.MarketDAGStoreConfig{
TransientsDir: filepath.Join(dagStoreDir, "transients"), TransientsDir: filepath.Join(dagStoreDir, "transients"),
IndexDir: filepath.Join(dagStoreDir, "index"), IndexDir: filepath.Join(dagStoreDir, "index"),
Datastore: dagStoreDS, Datastore: dagStoreDS,
GCInterval: 5 * time.Minute, GCInterval: 1 * time.Minute,
MaxConcurrentIndex: 5,
MaxConcurrentFetch: 2,
} }
dsw, err := dagstore.NewDagStoreWrapper(cfg, lotusAccessor) dsw, err := dagstore.NewDagStoreWrapper(cfg, lotusAccessor)