Skip to content

Panic when inspecting output when using dynamic providers #21581

@exekias

Description

@exekias

I got this error when trying to use ${docker.container.id} in an input config with default settings (master):

turing.local :: beats/x-pack/elastic-agent ‹master*› » ./elastic-agent inspect output -o default
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x48 pc=0x475d4dd]
goroutine 70 [running]:
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.promoteProcessors(0xc00020ce70, 0xc0001ebb00)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/emitter.go:218 +0x9d
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.renderInputs(0x4be61a0, 0xc0002074c0, 0xc000207120, 0x3, 0x4, 0xc0001ebe01, 0xc0001ebef0, 0xc0000edbd8, 0x400e0c6)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/emitter.go:200 +0x263
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.(*emitterController).update(0xc0001af3b0, 0x20, 0x20)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/emitter.go:105 +0x57c
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.(*emitterController).Set(0xc0001af3b0, 0xc000207120, 0x3, 0x4)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/emitter.go:88 +0xbd
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.emitter.func1(0xc000207120, 0x3, 0x4)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/emitter.go:154 +0x48
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/agent/application.(*waitForCompose).Run.func1(0xc000207120, 0x3, 0x4)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/agent/application/inspect_output_cmd.go:241 +0x4c
github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/composable.(*controller).Run.func1(0x4bdd620, 0xc000044c40, 0xc00038b2e0, 0xc0001a6a00, 0xc00038b280, 0xc000347100)
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/composable/controller.go:168 +0x637
created by github.com/elastic/beats/v7/x-pack/elastic-agent/pkg/composable.(*controller).Run
	/Users/exekias/go/src/github.com/elastic/beats/x-pack/elastic-agent/pkg/composable/controller.go:123 +0x77c

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions