mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
This commit is contained in:
parent
517947765a
commit
19f72c4b9a
2 changed files with 14 additions and 4 deletions
|
@ -4,7 +4,7 @@
|
|||
* you may not use this file except in compliance with the Elastic License.
|
||||
*/
|
||||
|
||||
import { LOGGING_TAG, KIBANA_MONITORING_LOGGING_TAG, } from './common/constants';
|
||||
import { LOGGING_TAG, KIBANA_MONITORING_LOGGING_TAG } from './common/constants';
|
||||
import { requireUIRoutes } from './server/routes';
|
||||
import { instantiateClient } from './server/es_client/instantiate_client';
|
||||
import { initMonitoringXpackInfo } from './server/init_monitoring_xpack_info';
|
||||
|
|
|
@ -4,7 +4,11 @@
|
|||
* you may not use this file except in compliance with the Elastic License.
|
||||
*/
|
||||
|
||||
import { KIBANA_STATS_TYPE_MONITORING } from '../../../common/constants';
|
||||
import {
|
||||
LOGGING_TAG,
|
||||
KIBANA_MONITORING_LOGGING_TAG,
|
||||
KIBANA_STATS_TYPE_MONITORING,
|
||||
} from '../../../common/constants';
|
||||
import { opsBuffer } from './ops_buffer';
|
||||
|
||||
/*
|
||||
|
@ -34,11 +38,17 @@ export function getOpsStatsCollector(server) {
|
|||
|
||||
// `process` is a NodeJS global, and is always available without using require/import
|
||||
process.on('SIGHUP', () => {
|
||||
this.log.info('Re-initializing Kibana Monitoring due to SIGHUP');
|
||||
server.log(
|
||||
['info', LOGGING_TAG, KIBANA_MONITORING_LOGGING_TAG],
|
||||
'Re-initializing Kibana Monitoring due to SIGHUP'
|
||||
);
|
||||
setTimeout(() => {
|
||||
stop();
|
||||
start();
|
||||
this.log.info('Re-initialized Kibana Monitoring due to SIGHUP');
|
||||
server.log(
|
||||
['info', LOGGING_TAG, KIBANA_MONITORING_LOGGING_TAG],
|
||||
'Re-initialized Kibana Monitoring due to SIGHUP'
|
||||
);
|
||||
}, 5 * 1000); // wait 5 seconds to avoid race condition with reloading logging configuration
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue