fix(inputs.logstash): Collect opensearch specific stats (#12536)

This commit is contained in:
Joshua Powers 2023-01-25 02:38:18 -07:00 committed by GitHub
parent e9356b5cb3
commit c73bf332c3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 4 deletions

View File

@ -264,11 +264,11 @@ func (logstash *Logstash) gatherPluginsStats(
accumulator.AddFields("logstash_plugins", failuresFields, pluginTags) accumulator.AddFields("logstash_plugins", failuresFields, pluginTags)
} }
/* /*
The elasticsearch output produces additional stats around The elasticsearch & opensearch output produces additional stats
bulk requests and document writes (that are elasticsearch specific). around bulk requests and document writes (that are elasticsearch
Collect those here and opensearch specific). Collect those below:
*/ */
if pluginType == "output" && plugin.Name == "elasticsearch" { if pluginType == "output" && (plugin.Name == "elasticsearch" || plugin.Name == "opensearch") {
/* /*
The "bulk_requests" section has details about batch writes The "bulk_requests" section has details about batch writes
into Elasticsearch into Elasticsearch