I am working on an asp.net mvc 4 website with a wcf-service file. My application is built using the main categories, subcategories, and products. Each product can be in only one subcategory, and my url is as follows:
/ maincategoryname / subcategoryname / {ProductID} / producttitle
And the corresponding track for tiny crumbs:
Home> Home Category> Subcategory> Producttitle
I am currently using MvcSitemapProvider to create my navigation menu and breadcrumbs. I load the entire url as dynamic nodes without a cache. This solution works for several products, but when I add 1000 products, the sitemap takes 6.5 seconds to fill, too long.
I have included caching in MvcSitemapProvider. Thus, the application loads much faster. But when the user adds a new product and goes to this new product (page). The URL is not yet in the sitemap because it uses the cache. Thus, my navigation and breadcrumbs are not generated.
My question is:
Is it possible to add a new node file to the sitemap at runtime after a user adds a new product?
Joppe source share