mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
[monitoring] only start bulk uploader once (#31307)
This commit is contained in:
parent
7937f1ae31
commit
b4864042f9
1 changed files with 7 additions and 1 deletions
|
@ -66,7 +66,13 @@ export class BulkUploader {
|
|||
|
||||
// this is internal bulk upload, so filter out API-only collectors
|
||||
const filterThem = _collectorSet => _collectorSet.getFilteredCollectorSet(c => c.ignoreForInternalUploader !== true);
|
||||
this._fetchAndUpload(filterThem(collectorSet)); // initial fetch
|
||||
|
||||
if (this._timer) {
|
||||
clearInterval(this._timer);
|
||||
} else {
|
||||
this._fetchAndUpload(filterThem(collectorSet)); // initial fetch
|
||||
}
|
||||
|
||||
this._timer = setInterval(() => {
|
||||
this._fetchAndUpload(filterThem(collectorSet));
|
||||
}, this._interval);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue