Revindex Storefront

How to improve performance

Last updated on 2023-10-13 6 mins. to read

Performance is dependent on several factors such as hardware, network speed, server load, etc. 

Software configuration

  • Ensure you are running .NET 4.5+ framework.
  • Ensure you are running the latest version of Revindex Storefront running the newest display templates. Newer releases often have significant performance enhancements.
  • Microsoft recommends setting the application pool to run in 32-bit worker process will reduce memory consumption by almost half. Under the application pool's Advanced Settings, set the Enable 32-bit applications to True.
  • Enable IIS static and dynamic compression. This will significantly improve download time.
  • Increase the recycle time to avoid recycling the application pool too frequently.
  • Increase the idle time to avoid restarting the IIS application pool too frequently. Use the suspend mode instead of terminating the application if possible.
  • Install Revindex Optimizer to speed up page loading time by up to 50% when set to "Memory" storage type.
  • Remove any unnecessary module controls on your page (side banner, footer, etc.).
  • Remove any unnecessary page loading spinners. Some themes may use javascript to show a loading spinner essentially blocking the page until the page has fully loaded. 
  • Add the optimizeCompilations="true" attribute to your web.config to recompile only files that changed. This can speed up start up time considerably. In most cases, this optimization will work correctly. If you experience any odd behavior for example after you install a new package, simply flip this switch back to "false" temporarily to force a full recompile.

    <compilation ... optimizeCompilations="true" >
  • Make sure your web.config SQL connection string specifies MultipleActiveResultSets=True as shown in the example below:

    <add name="SiteSqlServer" connectionString="Data Source=localhost; Initial Catalog=DNN; Integrated Security=True; MultipleActiveResultSets=True;" providerName="System.Data.SqlClient" />
  • Set your DNN Cache Settings to "Heavy" under Settings > Servers page. Please note caching takes effect and builds up speed after the first page visit.
  • Enable Page output cache for most of your static pages as well as for the Product List page. From the page settings, select the MemoryOutputCachingProvider and set a reasonable cache duration like 1800 seconds. Make sure to Include params by default. Depending on the functionality you enable, it may or may not be possible to use Page output cache because it may interfere with the DNN anti-forgery security token. Make sure to perform tests as both logged in and anonymous user after enabling the cache feature.
  • Make use of content delivery network (CDN) to host your common client scripts.
  • Make use of Client Resource Management composition and minify files under Settings > Servers page.
  • Reduce the high frequency runs of unimportant jobs under Settings > Scheduler page. For example, you don't always need to index your search every minute and can increase to 15 minutes.
  • Uninstall extensions that you don't use under Settings > Extensions page to reduce memory consumption.
  • Ensure your hosting does not place a limit your application pool's memory or CPU usage.
  • If you have a low traffic site, ensure your site is up and running using a keep-alive service to ping your site every 15 minutes. If your site idles too long, your hosting provider or IIS may shut down the process causing the first visit to take a long time to start up again.

Hardware changes

  • Ensure you have lots of free memory on the server so that your OS is not swapping to disk and the Web server is able to cache as much data as possible.

    Ideally, ensure the system can cache all your products to memory. On 64-bit mode, you can roughly calculate how much memory is needed for simple products = Avg. DB row size X Number of products X 10 factor. The factor of 10 will increase quickly if your product is complex and have many variants and attributes, so please test accordingly. For example, if your database product table uses about 1 KB of storage per row and you have 10,000 products, you can approximate a memory consumption of 50 MB just for caching products. If your application pool is running in 32-bit mode, the cache factor is usually half the factor at around 5 times. To find the row size, you can simply view your table properties and look for the table storage size and divide by the number of rows in that table.
  • Get faster hard drives for your database and file server. It's about the number of IO per second and not about storage size (SSD or 10K/15K rpm hard drives in RAID are recommended).
  • Get a very fast CPU for your Web server especially if you intend to use a lot of dynamic rules and promotions.
  • Revindex Storefront supports Web farm configuration allowing you to spread the load over multiple Web servers.
  • Ensure you have a fast ethernet connection between your Web server and database server if they're on separate machines (1 Gbps or higher is recommended).
  • Ensure you have a fast public network (100 Mbps or more).

Storefront configuration

  • Group your products using multiple categories and sub-categories to avoid displaying too many products on a single page. It's generally ineffective to list thousands of products on one category even with paging enabled, when the average customer never navigates past the 2nd page. Most major shopping sites use this approach to speed up performance. For example, a good way is to mark a limited number of products as Featured products, therefore, showing only the subset of products when no category is being selected instead of showing all products. Likewise, sub-category is a great way to force customers to quickly narrow down to what they're looking for instead of paging through hundreds of pages. In general, aim for no more than a hundred products per category.
  • Avoid creating unnecessary product variants when you can create product options with custom fields. Product variants are generally used when you need to track distinct inventory and SKU for each product option.
  • Minimize the use of rules such as price modifier, availability rule, promotion rule, etc.. If you must use rules, favor the rules provided from one of the basic form types over custom code.
  • Limit the use of product filter for only important attributes. Balance between speed and ease of navigation for your customers. Product filter is generally an intensive operation. Learn to take advantage of other forms of navigation filters like product search, category, manufacturer, distributor, etc.
  • Reduce the number of unnecessary modules on your page that can clutter and slow down the page rendering.
  • Set a small but reasonable limit on the number of results to show under Configuration > Product List and Configuration > Product Search settings. Study shows 80% of customers don't navigate past the 2nd page (e.g. 100 is a good limit). Rather than setting a high limit and expect the customer to click through 20 pages of products, you should emphasize the use of the product search module instead.
  • Disable natural sort under Configuration > Product list settings. The natural sort algorithm is an expensive operation.
  • Make sure your Log Level is set to "Error" mode under Configuration > General settings so that you're not logging unnecessary debug information.
  • Disable GeoIP under Configuration > General settings if you don't use that feature will reduce memory consumption by 30 MB.
  • Delete archived products under Configuration > General settings will reduce the memory usage if you had a lot of deleted products.
  • If you have a lot of products and wish to improve the start up time, you can enable asynchronous caching by adding the following keys to your web.config appSettings:

    <add key="RevindexStorefront.DataCacheAsync" value="true" />
    <add key="RevindexStorefront.DataCacheAsyncFetchSize" value="0.1" />
    <add key="RevindexStorefront.DataCacheAsyncMinCount" value="10000" />

    The DataCacheAsync tells the Storefront to load the cache asynchronously. When enabled, partial products may start to appear gradually.

    The DataCacheAsyncFetchSize is the percentage of records (e.g. 0.1 equals 10%) to load at a time until all records are loaded into the cache to avoid fetching incredibly large number of records for a every long time and potentially blocking other queries.

    The DataCacheAsyncMinCount tells it to load all records in chunks (see DataCacheAsyncFetchSize) only if the total number of records exceeds the number.



Powered by Revindex Wiki