-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
59194: kv: introduce a stopgap for lack of ReplicaState synchronization r=irfansharif a=irfansharif There's a scary lack of synchronization around how we set the ReplicaState for a given replica, and how we mark a replica as "initialized". What this means is that very temporarily, it's possible for the entry in Store.mu.replicas to be both "initialized" and have an empty ReplicaState. This was an existing problem, but is now more likely to bite us given the migrations infrastructure attempts to purge outdated replicas at start up time (when replicas are being initialized, and we're iterating through extan replicas in the Store.mu.replicas map). This issue has caused a bit of recent instability: #59180, #58489, \#58523, and #58378. While we work on a more considered fix to the problem (tracked in #58489), we can introduce stop the bleeding in the interim (and unskip some tests). Release note: None 59201: sql: add telemetry for materialized views and set schema. r=otan a=RichardJCai sql: add telemetry for materialized views and set schema. Release note: None Resolves #57299 Co-authored-by: irfan sharif <irfanmahmoudsharif@gmail.com> Co-authored-by: richardjcai <caioftherichard@gmail.com>
- Loading branch information
Showing
15 changed files
with
163 additions
and
13 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# This file contains telemetry tests for sql.schema.*_materialized_view.* counters. | ||
|
||
feature-allowlist | ||
sql.schema.create_materialized_view | ||
sql.schema.alter_materialized_view.owner_to | ||
sql.schema.alter_materialized_view.set_schema | ||
sql.schema.refresh_materialized_view | ||
sql.schema.drop_materialized_view | ||
---- | ||
|
||
feature-usage | ||
CREATE MATERIALIZED VIEW mvx AS SELECT 1 | ||
---- | ||
sql.schema.create_materialized_view | ||
|
||
feature-usage | ||
REFRESH MATERIALIZED VIEW mvx | ||
---- | ||
sql.schema.refresh_materialized_view | ||
|
||
feature-usage | ||
ALTER MATERIALIZED VIEW mvx OWNER TO root | ||
---- | ||
sql.schema.alter_materialized_view.owner_to | ||
|
||
exec | ||
CREATE SCHEMA ss | ||
---- | ||
|
||
feature-usage | ||
ALTER MATERIALIZED VIEW mvx SET SCHEMA ss | ||
---- | ||
sql.schema.alter_materialized_view.set_schema | ||
|
||
feature-usage | ||
DROP MATERIALIZED VIEW ss.mvx | ||
---- | ||
sql.schema.drop_materialized_view |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# This file contains telemetry tests for sql.schema.alter_*.set_schema counters. | ||
|
||
feature-allowlist | ||
sql.schema.alter_table.set_schema | ||
sql.schema.alter_sequence.set_schema | ||
sql.schema.alter_view.set_schema | ||
sql.schema.alter_materialized_view.set_schema | ||
---- | ||
|
||
exec | ||
CREATE SCHEMA ss | ||
---- | ||
|
||
exec | ||
CREATE TABLE t(); | ||
CREATE SEQUENCE s; | ||
CREATE VIEW vx AS SELECT 1; | ||
CREATE MATERIALIZED VIEW mvx AS SELECT 1 | ||
---- | ||
|
||
feature-usage | ||
ALTER TABLE t SET SCHEMA ss | ||
---- | ||
sql.schema.alter_table.set_schema | ||
|
||
feature-usage | ||
ALTER SEQUENCE s SET SCHEMA ss | ||
---- | ||
sql.schema.alter_sequence.set_schema | ||
|
||
feature-usage | ||
ALTER VIEW vx SET SCHEMA ss | ||
---- | ||
sql.schema.alter_view.set_schema | ||
|
||
feature-usage | ||
ALTER MATERIALIZED VIEW mvx SET SCHEMA ss | ||
---- | ||
sql.schema.alter_materialized_view.set_schema |