-
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.
52359: sql: drop the "experimental" in experimental_follower_read_timestamp r=andreimatei a=andreimatei The known badness with follower reads was fixed - most recently #49391, #44053 and #44878. At this point, the "experimental" prefix doesn't serve any purpose, and it unnecessarily raises questions. The previous name stays as an alias for backwards compatibility. Fixes #45243 Release note: The experimental_follower_read_timestamp() function was renamed to follower_read_timestamp(), signifying more confidence in CRDB's follower read implementation. The previous name remains a supported alias. 52534: sql: add notice for Alter TYPE ADD VALUE IF NOT EXIST command r=rohany a=himanshuchawla009 Fixes: #52327 Added a notice message similar to postgres if user tries to add a value in enum which already exists using IF NOT EXIST command. > root@:26257/defaultdb> alter type color ADD VALUE IF NOT EXISTS 'black'; ALTER TYPE > root@:26257/defaultdb> alter type color ADD VALUE IF NOT EXISTS 'black'; NOTICE: enum label "black" already exists, skipping However, I noticed similar behaviour in other command like ALTER TABLE command. Altering existing table with if not exist command doesn't shows any notice. Release note (sql change): Show notice to user when user tries to add value which already exists in enum . 52547: export/csv: prepend a unique id to file name of csv exports r=shermanCRL a=shermanCRL Addresses #50580 When exporting CSV files, a failed & repeated export will use the same file names. This can result in an error if an overwrite is disallowed, but more importantly, it can result in a directory containing files from different export runs. This can represent inconsistent data if the previous export was not deleted. This commit prepends a unique export ID to the file name. The ID is the queryID from the sql.Statement struct. This choice seems to guarantee the most uniqueness. It's 128 bits, and encoded as hex. Other ID options considered were random int, timestamp, and transaction ID. Each of these has a small risk of collision. Related tests were updated and are (should be) passing. Release note (enterprise change): Exported CSV files are now prepended with a long unique ID. This can help to mitigate situations where multiple export runs are written to the same directory, resulting in mixed data. This change does not prevent mixed data; rather, it makes it possible to identify files from distinct runs, so that an operator can clean up. Co-authored-by: Andrei Matei <[email protected]> Co-authored-by: himanshuchawla009 <[email protected]> Co-authored-by: Matt Sherman <[email protected]>
- Loading branch information
Showing
15 changed files
with
192 additions
and
100 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.