Drupal 11.5 Adds Views Post-Save API, Deprecates Cache Helper
Drupal 11.5 introduces a new post-save API for Views plugins and deprecates views_invalidate_cache(). A Drupal core change record published on 10 September 2026 says plugins, handlers, and displays can now indicate when routing or plugin discovery work is required after a View is saved. The change separates Views cache invalidation from the decision to rebuild routes.
The work addresses a long-running issue around unnecessary routing work when Views configuration is saved. Core issue #941970, opened in 2010, identifies cases such as block-only Views and page displays with unchanged paths where a router rebuild should not be necessary. The new API lets Views components signal when that work is actually required.
Plugins, handlers, and displays that need to act after a save can implement PostSaveViewInterface. View::postSave() calls postSaveView(PostSaveProcess $postSaveProcess, ?DisplayPluginInterface $original_display) on implementations, while PostSaveProcess tracks whether the router needs rebuilding and which plugin discovery caches should be cleared. When routing work is flagged, View::postSave() performs the rebuild once.
The procedural views_invalidate_cache() function is deprecated as part of the change. The change record directs developers to Views::invalidateCache() for Views cache invalidation and, outside a Views plugin context, to the router builder and Views route subscriber services for routing work. The change record lists module developers as affected, making the new API relevant to projects with custom Views plugins or direct calls to the deprecated helper.
