Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't stop Filebeat when modules + logstash are used together #3929

Merged
merged 1 commit into from
Apr 10, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion filebeat/beater/filebeat.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,11 @@ func New(b *beat.Beat, rawConfig *common.Config) (beat.Beater, error) {
func (fb *Filebeat) modulesSetup(b *beat.Beat) error {
esConfig := b.Config.Output["elasticsearch"]
if esConfig == nil || !esConfig.Enabled() {
return fmt.Errorf("Filebeat modules configured but the Elasticsearch output is not configured/enabled")
Copy link
Contributor

@dedemorton dedemorton Apr 6, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (couple of minor changes)

Filebeat modules are enabled, but the Elasticsearch output is not configured/enabled. This means Filebeat can't load the Ingest Node pipelines. If you have already loaded the pipelines, you can ignore this warning.

Not sure if this covers LS users, tho, because they really don't need to load the pipelines at all, right?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An alternate version (in case you want to shift the focus away from the idea that ES is required):

Filebeat is unable to load the Ingest Node pipelines for the configured modules because the Elasticsearch output is not configured/enabled. If you have already loaded the Ingest Node pipelines or are using Logstash pipelines, you can ignore this warning.

logp.Warn("Filebeat is unable to load the Ingest Node pipelines for the configured" +
" modules because the Elasticsearch output is not configured/enabled. If you have" +
" already loaded the Ingest Node pipelines or are using Logstash pipelines, you" +
" can ignore this warning.")
return nil
}
esClient, err := elasticsearch.NewConnectedClient(esConfig)
if err != nil {
Expand Down