Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adapter: Sync view names with the recipe
We were running into a bug where if a cache was created with a name, Readyset was restarted, and a read against that cache was executed, the "/view_builder" RPC couldn't find the view associated with the query. This was happening because the cache was being added to the expression registry with its name, but after Readyset restarts, the adapter doesn't know anything about the name. When it invokes "/view_builder," it uses the adapter query ID as the name in `ViewRequest`, but when the server looks up that name in the expression registry, it doesn't find anything (because the cache was added with a name other than the adapter query ID). This commit fixes the issue by 1) updating the `/view_statuses` controller RPC to return the names of the queries in the expression registry instead of just booleans and 2) updating the views synchronizer to update the view name cache used in the adapter with the names of the views. This also fixes an issue where different queries in the query status cache map to the same server-rewritten query, and versions of the query other than the version from which the cache was created could not be used to query the cache. Now, the views synchronizer will map all of these queries to the same view name. Fixes: REA-3933 Release-Note-Core: Fixed an issue where caches were not queryable after restarts in certain cases Change-Id: If55846bdec50023585a12f2693dbb7e0e9b28a4a Reviewed-on: https://gerrit.readyset.name/c/readyset/+/6864 Tested-by: Buildkite CI Reviewed-by: Luke Osborne <luke@readyset.io>
- Loading branch information
1 parent
c712538
commit a36d8da
Showing
15 changed files
with
223 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.