MCPcopy Index your code
hub / github.com/cortexproject/cortex / NewCompactorWithConfigFile

Function NewCompactorWithConfigFile

integration/e2ecortex/services.go:300–327  ·  view source on GitHub ↗
(name, consulAddress, configFile string, flags map[string]string, image string)

Source from the content-addressed store, hash-verified

298}
299
300func NewCompactorWithConfigFile(name, consulAddress, configFile string, flags map[string]string, image string) *CortexService {
301 if configFile != "" {
302 flags["-config.file"] = filepath.Join(e2e.ContainerSharedDir, configFile)
303 }
304
305 if image == "" {
306 image = GetDefaultImage()
307 }
308
309 return NewCortexService(
310 name,
311 image,
312 e2e.NewCommandWithoutEntrypoint("cortex", e2e.BuildArgs(e2e.MergeFlags(map[string]string{
313 "-target": "compactor",
314 "-log.level": "warn",
315 // Store-gateway ring backend.
316 "-compactor.sharding-enabled": "true",
317 "-compactor.ring.store": "consul",
318 "-compactor.ring.consul.hostname": consulAddress,
319 // Startup quickly.
320 "-compactor.ring.wait-stability-min-duration": "0",
321 "-compactor.ring.wait-stability-max-duration": "0",
322 }, flags))...),
323 e2e.NewHTTPReadinessProbe(httpPort, "/ready", 200, 299),
324 httpPort,
325 grpcPort,
326 )
327}
328
329func NewSingleBinary(name string, flags map[string]string, image string, otherPorts ...int) *CortexService {
330 if image == "" {

Callers 1

NewCompactorFunction · 0.85

Calls 7

BuildArgsFunction · 0.92
MergeFlagsFunction · 0.92
NewHTTPReadinessProbeFunction · 0.92
GetDefaultImageFunction · 0.85
NewCortexServiceFunction · 0.85
JoinMethod · 0.80

Tested by

no test coverage detected