views_invalidate_cache() has been deprecated. Use Views::invalidateCache() for cache invalidation. For route rebuilding, call the router.builder and views.route_subscriber services directly. If those operations need to be done in a Views plugin context, the following applies:
Plugins, handlers and displays can now implement PostSaveViewInterface to act on view save: View::postSave() calls postSaveView(PostSaveProcess $postSaveProcess, ?DisplayPluginInterface $original_display) on every plugin that implements the interface.
PostSaveProcess tracks post-save state:
setRouterRebuild(): flag that the router needs rebuilding.
needsRouterRebuild(): check if router needs rebuilding - View::postSave() rebuilds it once if needed.
addDiscoveryToClear(): queue a CachedDiscoveryInterface plugin manager to have its clearCachedDefinitions() called.