How to Cache Imported Product Files in Magento 2

- Magento 2, Our extensions

We’ve already described how to import 100,000 products to Magento 2 in less than an hour. However, you can speed up the import process even more by caching imported product files and using the cached data for further updates. Note that this functionality is available only in the Improved Import & Export Magento 2 extension. In the following article, we describe how this feature works. Next, you will learn how to cache imported product files in Magento 2 to speed up product updates. Follow our Magento 2 Developer’s Cookbook for more recommendations on how to improve your daily data transfers and other routine processes.

Enabled Cache Products: The Option’s Definition & Impact

Enabled Cache Products” is a vital time saver for regular product updates. The feature enables caching for product files that you upload to your e-commerce website.  

This cache is implemented as a part of the native Magento 2 caching system. It means that flushing cache also flushes cache for the import jobs. 

The “Enabled Cache Products” feature works as follows. You provide a product update file to the import job. The Improved Import & Export extension calculates the hash value for all rows in the imported product table. After the import procedure is complete, these row hash values are cached. 

As a result, the data transfer associated with a consecutive import of the SAME file is sped up dramatically. If attributes in particular rows have been changed, the extension imports only these attributes because their hash values differ from the cached ones. Changing the row order will also result in different hash values. 

So, if your update file consists of thousands of attributes but only a dozen of them have been changed, the Improved Import & Export will import only these dozen, speeding up the import process. The “Enabled Cache Products” feature should be enabled. The update file should be already cached.
If you need to nullify the cache for the imported file, just flush the Magento 2 cache storage or flush Cache Import Products. Note that disabling the “Enable Cache Products” setting will NOT flush the cached rows.

How to Cache Imported Product Files in Magento 2

The whole process of caching imported product files is reduced to a single click: 

  1. Create a new import job. You can find the “Add New Job” button under System -> Improved Import/Export -> Import Jobs.
  2. Enable your job and specify its title on the General Settings tab. You can also configure the update frequency if necessary.
  3. Choose Products as your import entity on the Import Settings tab. Additional settings display.
    Magento 2 Products add edit import export

  4. Scroll down to the “Enabled Cache Products” option and turn it on to cache product data during Magento 2 import.
  5. Configure other parameters and save your import job.

Now, you can import products to Magento 2, caching them to speed up further product updates. For further information on how to import Magento 2 products, follow these links: The Complete Guide to Magento 2 Product Import & How to update Magento 2 product price and quantity using import and export.

Improved Import & Export Features

Caching products upon import in Magento 2 isn’t the only advantage of Improved Import & Export. The extension, as previously said, completely redesigns the default import and export operations of the platform. 

You will, for example, be able to prevent time-consuming and unpleasant file adjustments.  Because Magento 2 only supports CSV files, all other file formats should be converted to this format. The Improved Import extension, on the other hand, allows you to import and export files in CSV, XML, JSON, ODS, and XLSX formats.

Along with that, numerous file sources, including Google Drive and Dropbox, are at your disposal. It is also possible to use FTP/SFTP, direct file uploads, and URL uploads to exchange data between Magento 2 and other systems. Or you can import and export updates using Google Sheets

Magento 2 Products add edit import export

You may also avoid using third-party services thanks to the extensive API support. Import & Export enables direct API transfers to connect your e-commerce website to external systems, introducing a whole new approach for importing and exporting data between Magento 2 and external systems.

Another important innovation included in every import and export profile is scheduling. It allows you to update your e-commerce website automatically at predetermined intervals. 

Furthermore, the extension’s comprehensive mapping features enable you to convert third-party attributes to Magento 2 properties, as well as create new attributes and values as needed. Visit the following websites for further information: