Data Emitter Issues
Resolve Data Emitter errors, including duplicate emitters and OpenSearch buffer limits.
Below are the issues related to Data Receiver:
- Data Emitter Error and Resolution
Data Emitter Error and Resolution#
Encountered an issue where two Data Emitters were running simultaneously, which resulted in errors related to data processing and field data operations in OpenSearch. Specifically, the error was caused by a failure in field aggregation and sorting due to improper field type settings. Additionally, the data emitter was overloading the system with excessive file watch operations.
Errors:
-
Field Data Aggregation Error:
[{"error":{"root_cause": [{"type":"illegal_argument_exception","reason":"Text fields are not optimized for operations that require per-document field data like aggregations and sorting, so these operations are disabled by defaultCause : Misconfiguration of text fields (kpiIdentifier ) for aggregation or sorting in OpenSearch.
- The error suggests using a keyword field instead or enabling fielddata=true to handle the operations.
- Search Phase Execution Exception:
org.opensearch.OpenSearchStatusException: OpenSearch exception [type=search_phase_execution_exception, reason=all shards failed]Cause : Search failure across shards, likely due to incorrect query parameters or an overwhelmed system trying to process too many files simultaneously.
-
Buffer Limit Exceeded:
java.io.IOException: entity content is too long [123806273] for the configured buffer limit [104857600]Cause : The Data Emitter attempted to process an entity that exceeded the configured buffer limit (100MB)
Solution :
a. Execute the command to query the KPI indices to better understand the ongoing data processing:
curl -k -u admin:<password> -XGET
"https://192.0.2.113:9200/heal_raw_kpi_*,heal_error_kpi_*/_search"
-H 'Content-Type: application/json' -d'{"size": 0, "query": {
"bool": { "filter": [ { "range": { "timeInGMT": { "from":
1723632960000, "to": 1723633260000, "include_lower": true,
"include_upper": false, "boost": 1 } } }, { "term": { "kpiType": {
"value": "FileWatch", "boost": 1 } } } ], "should": [ { "term": {
"metadata.watcherValueCollated": { "value": "false", "boost": 1 } }
}, { "bool": { "must_not": [ { "exists": { "field":
"metadata.watcherValueCollated", "boost": 1 } } ],
"adjust_pure_negative": true, "boost": 1 } } ],
"adjust_pure_negative": true, "minimum_should_match": "1", "boost":
1 }, "aggregations": { "KpiAggs": { "terms": { "field":
"kpiIdentifier", "size": 10000, "min_doc_count": 1,
"shard_min_doc_count": 0, "show_term_doc_count_error": false,
"order": [ { "_count": "desc" }, { "_key": "asc" } ] },
"aggregations": { "InstanceAggs": { "terms": { "field":
"compInstanceIdentifier", "size": 10000, "min_doc_count": 1,
"shard_min_doc_count": 0, "show_term_doc_count_error": false,
"order": [ { "_count": "desc" }, { "_key": "asc" } ] },
"aggregations": { "GrpAttrAggs": { "terms": { "field":
"groupAttribute", "size": 10000, "min_doc_count": 1,
"shard_min_doc_count": 0, "show_term_doc_count_error": false,
"order": [ { "_count": "desc" }, { "_key": "asc" } ] },
"aggregations": { "WatcherAggs": { "top_hits": { "from": 0, "size":
10, "version": false, "seq_no_primary_term": false, "explain":
false, "sort": [ { "timeInGMT": { "order": "desc" } } ] } } } } } }
} } } }'
b. The query filtered records based on time range and checked for the kpiIdentifier and watcherValueCollated flags.
2. Identified Cause : The excessive query execution time was due to a large number of files (over 2000 FileWatcher files) being processed simultaneously, overloading the Data Emitter and causing buffer overflows.
3. Resolution : Recommend changing the data collection mode from 'on ' to 'off ' for files that were not needed, reducing the load on the system.
a. Restart the Data Emitter and observe significant improvements. The buffer overload issue will be resolved after reducing the active file watch count.