To reindex a specific indexer, please use below
use Magento\Framework\App\Bootstrap;
require __DIR__ . '/app/bootstrap.php';
$params = $_SERVER;
$bootstrap = Bootstrap::create(BP, $params);
$obj = $bootstrap->getObjectManager();
$indexer = $obj->get('Magento\Framework\Indexer\IndexerRegistry')->get('design_config_grid');
$indexer->reindexAll();
use Magento\Framework\App\Bootstrap;
require __DIR__ . '/app/bootstrap.php';
$params = $_SERVER;
$bootstrap = Bootstrap::create(BP, $params);
$obj = $bootstrap->getObjectManager();
$indexer = $obj->get('Magento\Framework\Indexer\IndexerRegistry')->get('design_config_grid');
$indexer->reindexAll();
No comments:
Post a Comment