Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
50949: backupccl: handle sequence ownership remapping logic for restore r=pbardea a=arulajmani Previously, we would restore sequence descriptors/table descriptors as is, without remapping the ownership dependency to the new IDs. This meant sequence ownership was broken post restore. This PR fixes that. When sequences with owners or tables that have columns that own sequences are restored: - If both the owned sequence and the owning table are being restored, the ownership is remapped. - If just the sequence is restored, the user receives an error to use the `skip_missing_sequence_owners` flag. If the flag is provided, the sequence is restored without any owner. - If just the table is restored, the user receives an error to use the `skip_missing_sequence_owners` flag. If the flag is provided, the table is restored with the table column that previously owned the sequence no longer owning that sequence. Fixes #50781 Release note (enterprise change): Restore now has a new option `skip_missing_sequence_owners` that must be supplied when restoring only the table/sequence that was previously a sequence owner/owned by a table. Additionally, this fixes a bug where ownership relationships would not be remapped after a restore. 51005: build: fix package reported by acceptance and compose r=otan a=tbg The acceptance and compose tests were previously reporting `emptypkg` as their package, which would be used to create issues. We need to pass the "real" package to go so that it shows up in the JSON output. Closes #51003. Release note: None 51037: sql: change volatility of timezone with TIME and TIMETZ to stable r=mgartner a=mgartner sql: change volatility of timezone with TIME and TIMETZ to stable The `timezone(STRING, TIME)` and `timezone(STRING, TIMETZ)` function overloads were originally marked as volatile to copy Postgres's volatility for the `timezone(STRING, TIMETZ)` overload (Postgres does not implement `timezone (STRING, TIME)`. Postgres's volatility settings for all overloads of `timezone` are below. Name | Argument data types | Volatility ----------+---------------------------------------+------------------ timezone | interval, time with time zone | immutable zone timezone | interval, timestamp with time zone | immutable timezone | interval, timestamp without time zone | immutable timezone | text, time with time zone | volatile zone timezone | text, timestamp with time zone | immutable timezone | text, timestamp without time zone | immutable This single overload is singled out as volatile by Postgres because it is dependent on C's `time(NULL)`. See the Postgres commit originally marking this overload volatility, and the lines of code showing the dependence: postgres/postgres@35979e6 https://github.com/postgres/postgres/blob/ac3a4866c0bf1d7a14009f18d3b42ffcb063a7e9/src/backend/utils/adt/date.c#L2816 CRDB does not have the same issue. All `timezone` overloads have the same volatility, stable. This commit marks them as such. Additional context: #48756 (comment) This commit also moves the `IgnoreVolatilityCheck` field from function definitions to overloads. This allows overloads of the same function to be ignored when asserting that the volalitity of an overload matches Postgres's assigned volatility. Release note: None 51071: roachtest: fix acceptance/decommission r=darinpp a=darinpp The added --self flag makes the test fail with 20.1 and 19.2 With 20.1 the flag is not supported and so the expected result should reflect that the step where a node decommissions self will not happen. With 19.2 the match that --self is not supported doesn't work as the error message capitalization differs. The fix changes the expected result and corrects the match of --self not supported to work with 19.2 as well Release note: None Co-authored-by: arulajmani <[email protected]> Co-authored-by: Tobias Schottdorf <[email protected]> Co-authored-by: Marcus Gartner <[email protected]> Co-authored-by: Darin <[email protected]>
- Loading branch information