• Resolved Danila Vershinin

    (@dvershinin)


    Hi, it appears that the plugin doesn’t have any hooks exposed that fire off *after* a sitemap is generated, and I don’t know whether the plugin tracks if anything changed (so thus not sending last-modified header). Can this be added?

    That way plugins like proxy cache plugin can purge sitemap URLs when they change, making proper cache in Varnish or NGINX possible. The current fully dynamic sitemap generation approach lacks this caching support.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Auctollo

    (@auctollo)

    @dvershinin If your server config adds the appropriate headers like etags or expires to .xml files you should be able to have your reverse proxy cache the objects.

    Thread Starter Danila Vershinin

    (@dvershinin)

    @Auctollo?in case of this plugin, .xml files are no longer generated. So there’s no caching validator like last-modified or etag available via filesystem. It is the plugin’s responsibility to provide those headers because .xml is dynamically generated on every request.

    Plugin Author Auctollo

    (@auctollo)

    @dvershinin I respect your opinion.

    However, the challenge is that the plugin has been this way for nearly a decade. And to be clear, last time I checked, no other popular indexation or SEO plugins are adding headers to their files either.

    If you wish, caching plugins or simply adding some directives to the web server config will successfully set caching headers on sitemap files. That is my recommendation. There will be no changes to the plugin to add caching headers to the files.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘No way to cache reliably in Varnish’ is closed to new replies.