Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Index Invalidation Debugger Settings

Field

Optiona

Comment

Enable Logging

Yes/No 

Enables logging all index invalidation along with stacktraces.

Logging retention period

How long (in days) logs should be kept

The index logger link can be found in System -> Tools -> Index Management

...

Backend

AdminHtml - Index invalidation log action

vendor/creativestyle/magesuite-index-invalidation-logger/Controller/Adminhtml/Log/Index.php:7
Code Block
breakoutModewide
class Index extends \Magento\Backend\App\Action
{
    public function execute()
    {
        $resultPage = $this->resultFactory->create(\Magento\Framework\Controller\ResultFactory::TYPE_PAGE);
        $resultPage->getConfig()->getTitle()->set(__('Index invalidation log'));

        return $resultPage;
    }
}

Cron - cleanup logs

vendor/creativestyle/magesuite-index-invalidation-logger/Cron/LogsCleanup.php:26

Code Block
breakoutModewide
class LogsCleanup
{
    public function execute()
    {
        if (!$this->configuration->isLoggingEnabled()) {
            return;
        }

        $this->cleanLogs->execute($this->configuration->getLoggingRetentionPeriod());
    }
}

Command - cleanup logs

Is used by previous mentioned cron

vendor/creativestyle/magesuite-index-invalidation-logger/Model/Command/CleanLogs.php:17
Code Block
class CleanLogs
{
    public function execute($retentionPeriodInDays) {
        .....

        $logsTable = $this->connection->getTableName('index_invalidation_log');

        $this->connection->delete(
            $logsTable,
            "executed_at < date_sub(CURDATE(), INTERVAL ".$retentionPeriodInDays." Day)"
        );
    }
}

Frontend

There are no frontend functionalities in the module.