<?xml version="1.0"?>
<!--
/**
 * Copyright © Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\InventoryIndexer\Indexer\Stock\StockIndexer">
        <plugin name="invalidate_products_cache" type="Magento\InventoryCache\Plugin\InventoryIndexer\Indexer\Stock\StockIndexer\CacheFlush"/>
    </type>
    <type name="Magento\InventoryIndexer\Indexer\SourceItem\SourceItemIndexer">
        <plugin name="invalidate_products_cache" type="Magento\InventoryCache\Plugin\InventoryIndexer\Indexer\Source\SourceItemIndexer\CacheFlush"/>
    </type>
    <type name="Magento\InventoryCache\Model\ResourceModel\GetProductIdsByStockIds">
        <arguments>
            <argument name="productTableName" xsi:type="string">catalog_product_entity</argument>
        </arguments>
    </type>
    <type name="Magento\InventoryCache\Model\FlushCacheByProductIds">
        <arguments>
            <argument name="productCacheTag" xsi:type="const">Magento\Catalog\Model\Product::CACHE_TAG</argument>
        </arguments>
    </type>
</config>
