-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(lib): add
stats.Cache
to the lib instance as stats
added `stats` field of type `stats.Stats` to the `InstanceOptions` and `Instance` struct. `newStats` func is called in `NewInstance`. We create a new Cache based on the `cfg.Stats.Type` given in config (for now only option is "fs"), with a MaxSize of `cfg.Stats.MaxSize` (by default 25MiB). The cache is saved based on the `repoPath`, or `cfg.Stats.Path` if it's given.
- Loading branch information
Showing
2 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters