fix: gc was being stupid allowing another thread to take the space it made before it could not anymore
All checks were successful
PR Check / check-and-test (pull_request) Successful in 12s
All checks were successful
PR Check / check-and-test (pull_request) Successful in 12s
This commit is contained in:
14
cmd/root.go
14
cmd/root.go
@@ -15,12 +15,10 @@ import (
|
||||
var (
|
||||
threads int
|
||||
|
||||
memory string
|
||||
memorymultiplier int
|
||||
disk string
|
||||
diskmultiplier int
|
||||
diskpath string
|
||||
upstream string
|
||||
memory string
|
||||
disk string
|
||||
diskpath string
|
||||
upstream string
|
||||
|
||||
logLevel string
|
||||
logFormat string
|
||||
@@ -69,9 +67,7 @@ var rootCmd = &cobra.Command{
|
||||
sc := steamcache.New(
|
||||
address,
|
||||
memory,
|
||||
memorymultiplier,
|
||||
disk,
|
||||
diskmultiplier,
|
||||
diskpath,
|
||||
upstream,
|
||||
)
|
||||
@@ -99,9 +95,7 @@ func init() {
|
||||
rootCmd.Flags().IntVarP(&threads, "threads", "t", runtime.GOMAXPROCS(-1), "Number of worker threads to use for processing requests")
|
||||
|
||||
rootCmd.Flags().StringVarP(&memory, "memory", "m", "0", "The size of the memory cache")
|
||||
rootCmd.Flags().IntVarP(&memorymultiplier, "memory-gc", "M", 10, "The gc value for the memory cache")
|
||||
rootCmd.Flags().StringVarP(&disk, "disk", "d", "0", "The size of the disk cache")
|
||||
rootCmd.Flags().IntVarP(&diskmultiplier, "disk-gc", "D", 100, "The gc value for the disk cache")
|
||||
rootCmd.Flags().StringVarP(&diskpath, "disk-path", "p", "", "The path to the disk cache")
|
||||
|
||||
rootCmd.Flags().StringVarP(&upstream, "upstream", "u", "", "The upstream server to proxy requests overrides the host header from the client but forwards the original host header to the upstream server")
|
||||
|
||||
Reference in New Issue
Block a user