remove tmetaconsole_history token pandora_enterprise#9579
This commit is contained in:
parent
af7cbc5901
commit
4609e141ee
|
@ -784,14 +784,7 @@ function config_update_config()
|
|||
case 'perf':
|
||||
// PERFORMANCE SETUP.
|
||||
if (config_update_value('event_purge', get_parameter('event_purge'), true) === false) {
|
||||
$check_metaconsole_events_history = get_parameter('metaconsole_events_history', -1);
|
||||
$error_update[] = $check_metaconsole_events_history;
|
||||
}
|
||||
|
||||
if ($check_metaconsole_events_history != -1) {
|
||||
if (config_update_value('metaconsole_events_history', get_parameter('metaconsole_events_history'), true) === false) {
|
||||
$error_update[] = __('Max. days before delete events');
|
||||
}
|
||||
$error_update[] = __('Event purge');
|
||||
}
|
||||
|
||||
if (config_update_value('trap_purge', get_parameter('trap_purge'), true) === false) {
|
||||
|
@ -2107,10 +2100,6 @@ function config_process_config()
|
|||
config_update_value('event_purge', 15);
|
||||
}
|
||||
|
||||
if (!isset($config['metaconsole_events_history'])) {
|
||||
config_update_value('metaconsole_events_history', 0);
|
||||
}
|
||||
|
||||
if (!isset($config['realtimestats'])) {
|
||||
config_update_value('realtimestats', 1);
|
||||
}
|
||||
|
|
|
@ -1679,7 +1679,7 @@ function events_get_all(
|
|||
$result_meta = Promise\wait(
|
||||
parallelMap(
|
||||
$metaconsole_connections,
|
||||
function ($node_int) use ($sql) {
|
||||
function ($node_int) use ($sql, $history) {
|
||||
try {
|
||||
if (is_metaconsole() === true
|
||||
&& (int) $node_int > 0
|
||||
|
@ -1688,7 +1688,7 @@ function events_get_all(
|
|||
$node->connect();
|
||||
}
|
||||
|
||||
$res = db_get_all_rows_sql($sql);
|
||||
$res = db_get_all_rows_sql($sql, $history);
|
||||
if ($res === false) {
|
||||
$res = [];
|
||||
}
|
||||
|
@ -1819,7 +1819,7 @@ function events_get_all(
|
|||
}
|
||||
}
|
||||
|
||||
return db_get_all_rows_sql($sql);
|
||||
return db_get_all_rows_sql($sql, $history);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1443,7 +1443,9 @@ if ($pure) {
|
|||
}
|
||||
|
||||
// If the history event is not enabled, dont show the history tab.
|
||||
if (isset($config['metaconsole_events_history']) === false || $config['metaconsole_events_history'] != 1) {
|
||||
if (isset($config['history_db_enabled']) === false
|
||||
|| (bool) $config['history_db_enabled'] === false
|
||||
) {
|
||||
unset($onheader['history']);
|
||||
}
|
||||
|
||||
|
|
|
@ -660,7 +660,6 @@ sub pandora_load_config_pdb ($) {
|
|||
$conf->{'_delete_old_network_matrix'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'delete_old_network_matrix'");
|
||||
$conf->{'_enterprise_installed'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'enterprise_installed'");
|
||||
$conf->{'_metaconsole'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'metaconsole'");
|
||||
$conf->{'_metaconsole_events_history'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'metaconsole_events_history'");
|
||||
$conf->{'_netflow_max_lifetime'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'netflow_max_lifetime'");
|
||||
$conf->{'_netflow_nfexpire'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'netflow_nfexpire'");
|
||||
$conf->{'_netflow_path'} = get_db_value ($dbh, "SELECT value FROM tconfig WHERE token = 'netflow_path'");
|
||||
|
|
Loading…
Reference in New Issue