I want to cache full pages on our web application (thousands of pages) that are rendered by the Rails stack, but don't change very often. Each render is quite expensive in terms of resources.
My understanding of how Varnishd works is that when an initial call is made to a URL, Varnishd will check its cache store, a miss will take place and so the request will be passed through to Rails and resulting page which gets generated is then added to the Varnishd cache.
Any subsequent calls made to that URL and then served from the Varnishd cache, the Rails stack is not involved.
Is this correct or am I way off?
How can have my app tell Varnishd when a specific page has been updated & to reflect any changes made in its cache store?
Is Varnishd a good choice for this purpose?
Thanks for your help - I know these are very basic questions, but docs just don't make this clear (to me at least).