mirror of https://github.com/MISP/MISP
chg: [diagnostic:DBIndexes] Cleanup, bug fix and updated db_schema
parent
637e2806ef
commit
7be275aced
|
@ -524,7 +524,7 @@ class AdminShell extends AppShell
|
|||
$dbVersion = $dbVersion['AdminSetting']['value'];
|
||||
$data = array(
|
||||
'schema' => $dbActualSchema['schema'],
|
||||
'indexes' => $dbActualSchema['indexes']
|
||||
'indexes' => $dbActualSchema['indexes'],
|
||||
'db_version' => $dbVersion
|
||||
);
|
||||
$file = new File(ROOT . DS . 'db_schema.json', true);
|
||||
|
|
|
@ -4640,14 +4640,6 @@ class Server extends AppModel
|
|||
|
||||
public function compareDBIndexes($actualIndex, $expectedIndex)
|
||||
{
|
||||
$expectedIndex = $actualIndex;
|
||||
unset($actualIndex['decaying_models']);
|
||||
unset($actualIndex['feeds'][0]);
|
||||
unset($actualIndex['feeds'][1]);
|
||||
unset($actualIndex['galaxy_reference'][0]);
|
||||
unset($actualIndex['galaxy_reference'][3]);
|
||||
unset($actualIndex['notification_logs'][1]);
|
||||
unset($expectedIndex['threads'][2]);
|
||||
$indexDiff = array();
|
||||
foreach($expectedIndex as $tableName => $indexes) {
|
||||
if (!array_key_exists($tableName, $actualIndex)) {
|
||||
|
|
|
@ -9,6 +9,9 @@
|
|||
<strong><?php echo __('Notice'); ?></strong>
|
||||
<?php echo __('The highlighted issues may be benign. if you are unsure, please open an issue and ask for clarification.'); ?>
|
||||
</div>
|
||||
<?php if(empty($diagnostic)): ?>
|
||||
<span class="label label-success"><?php echo __('Index diagnostic:'); ?><i class="fa fa-check"></i></span>
|
||||
<?php else: ?>
|
||||
<table id="tableDBIndexes" class="table table-condensed table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
|
@ -47,6 +50,7 @@
|
|||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue