fork of https://github.com/sourcegraph/zoekt
0

Configure Feed

Select the types of activity you want to include in your feed.

Remove block profile rate config (#818)

Tiny clean-up, as we rarely use Datadog profiling (and I've never heard of us setting this env var).

-6
-6
cmd/zoekt-sourcegraph-indexserver/main.go
··· 1235 1235 listen string 1236 1236 hostname string 1237 1237 cpuFraction float64 1238 - blockProfileRate int 1239 1238 1240 1239 // config values related to shard merging 1241 1240 disableShardMerging bool ··· 1258 1257 fs.StringVar(&rc.listen, "listen", ":6072", "listen on this address.") 1259 1258 fs.StringVar(&rc.hostname, "hostname", zoekt.HostnameBestEffort(), "the name we advertise to Sourcegraph when asking for the list of repositories to index. Can also be set via the NODE_NAME environment variable.") 1260 1259 fs.Float64Var(&rc.cpuFraction, "cpu_fraction", 1.0, "use this fraction of the cores for indexing.") 1261 - fs.IntVar(&rc.blockProfileRate, "block_profile_rate", getEnvWithDefaultInt("BLOCK_PROFILE_RATE", -1), "Sampling rate of Go's block profiler in nanoseconds. Values <=0 disable the blocking profiler Var(default). A value of 1 includes every blocking event. See https://pkg.go.dev/runtime#SetBlockProfileRate") 1262 1260 fs.DurationVar(&rc.backoffDuration, "backoff_duration", getEnvWithDefaultDuration("BACKOFF_DURATION", 10*time.Minute), "for the given duration we backoff from enqueue operations for a repository that's failed its previous indexing attempt. Consecutive failures increase the duration of the delay linearly up to the maxBackoffDuration. A negative value disables indexing backoff.") 1263 1261 fs.DurationVar(&rc.maxBackoffDuration, "max_backoff_duration", getEnvWithDefaultDuration("MAX_BACKOFF_DURATION", 120*time.Minute), "the maximum duration to backoff from enqueueing a repo for indexing. A negative value disables indexing backoff.") 1264 1262 ··· 1368 1366 1369 1367 // Tune GOMAXPROCS to match Linux container CPU quota. 1370 1368 _, _ = maxprocs.Set() 1371 - 1372 - // Set the sampling rate of Go's block profiler: https://github.com/DataDog/go-profiler-notes/blob/main/guide/README.md#block-profiler. 1373 - // The block profiler is disabled by default and should be enabled with care in production 1374 - runtime.SetBlockProfileRate(conf.blockProfileRate) 1375 1369 1376 1370 // Automatically prepend our own path at the front, to minimize 1377 1371 // required configuration.