{"payload":{"feedbackUrl":"https://github.com/orgs/community/discussions/53140","repo":{"id":804345676,"defaultBranch":"master","name":"cockroach","ownerLogin":"spilchen","currentUserCanPush":false,"isFork":true,"isEmpty":false,"createdAt":"2024-05-22T12:24:24.000Z","ownerAvatar":"https://avatars.githubusercontent.com/u/171762?v=4","public":true,"private":false,"isOrgOwned":false},"refInfo":{"name":"","listCacheKey":"v0:1727464810.0","currentOid":""},"activityList":{"items":[{"before":null,"after":"e895c0ce8de291129767c6c688947b7f6e0248b6","ref":"refs/heads/crdb-42309/resolve-serverless","pushedAt":"2024-09-27T19:20:10.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Permit secondary tenant to read cluster initialization timestamp\n\nPreviously, the secondary tenant could not access the cluster\ninitialization timestamp, as it is stored in the system keyspace, and\ntenants are restricted to their own keyspace. This change introduces an\nexception that allows cross-tenant read access to this specific key\nwithin the system keyspace. Write access remains restricted, and any\nattempts to modify this key will still result in an error.\n\nThis change will be backported to 24.2, 24.1, 23.2 and 23.1.\n\nEpic: None\nCloses CRDB-42309\nRelease note: none","shortMessageHtmlLink":"server/license: Permit secondary tenant to read cluster initializatio…"}},{"before":null,"after":"62936895d670b4cba7e7170bb9f9ee2c0b540426","ref":"refs/heads/issue-130282/same-stage","pushedAt":"2024-09-27T13:03:07.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql/schemachanger: Ensure new PK is visible and old secondary is invisible in the same stage\n\nWe encountered a situation where, during a primary key modification, the old\nsecondary index was used to retrieve a column from the new primary key. This\ntriggered an assertion failure because the query assumed that all secondary\nindexes include the primary key columns as a prefix, which was not the case for\nthe old secondary index.\n\nThis change ensures that when the new primary key becomes visible, the old\nsecondary index is made invisible within the same stage. There are two\ndependency rules involved here: one ensures the primary key is in place before\nthe secondary index, and another handles the swap between old and new secondary\nindexes. Both rules have been adjusted to execute within the same stage.\n\nNote: I was unable to reproduce the issue, so no new test case has been added.\n\nEpic: None\nCloses #130282\nRelease note: None","shortMessageHtmlLink":"sql/schemachanger: Ensure new PK is visible and old secondary is invi…"}},{"before":"08e000634f5ccade168fc8e160eb0310d2b25426","after":"fcf3009e58b92ead22481768eee3909765e3271d","ref":"refs/heads/master","pushedAt":"2024-09-27T12:53:59.000Z","pushType":"push","commitsCount":76,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge #131218\n\n131218: roachprod: validate cloud providers r=herkolategan a=herkolategan\n\nPreviously, when calling the `create` command, it was possible to pass the same cloud twice by specifying `-c` or `--clouds` for the same provider more than once. There was no early validation that caught this and the resulting error after attempting to create the cluster would be confusing.\r\n\r\nThis change adds validation that warns the user early on a duplicate provider has been passed.\r\n\r\nEpic: None\r\nRelease note: None\n\nCo-authored-by: Herko Lategan ","shortMessageHtmlLink":"Merge cockroachdb#131218"}},{"before":"502899192194f45ac7e740ef58e8e163c84ec30a","after":null,"ref":"refs/heads/issue-127014/debug-deprules","pushedAt":"2024-09-26T20:39:47.000Z","pushType":"branch_deletion","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"}},{"before":null,"after":"a11a983907beb7c8ce81396d12f1206dfa3cbb9b","ref":"refs/heads/backport23.1-131284","pushedAt":"2024-09-26T14:33:12.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Add notice for upcoming throttling\n\nPreviously, throttling errors would only occur when active throttling was in\neffect. This update adds notices to alert clients when throttling is imminent,\nwithout disrupting running queries. A notice will be returned in the following\ncases:\n- If no license is installed or the license has expired, but we are still\n within the grace period.\n- If the license requires telemetry and no telemetry data has been received in\n the past 3 days.\n\nIn both cases, a notice is triggered only if the max limit of 5 concurrent open\ntransactions is exceeded.\n\nAdditionally, notices are logged to cockroach.log at most once every 5 minutes.\nThis commit also cleans up prior logging code by utilizing log.Every() for more\nefficient log gating.\n\nThis will be backported to 24.2, 24.1, 23.2 and 23.1.\n\nEpic: CRDB-39988\nCloses CRDB-39992\nRelease note: None","shortMessageHtmlLink":"server/license: Add notice for upcoming throttling"}},{"before":null,"after":"d49b9b919d93fbf107d382e5252ea648d78f9f34","ref":"refs/heads/backport23.2-131284","pushedAt":"2024-09-26T14:30:32.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Add notice for upcoming throttling\n\nPreviously, throttling errors would only occur when active throttling was in\neffect. This update adds notices to alert clients when throttling is imminent,\nwithout disrupting running queries. A notice will be returned in the following\ncases:\n- If no license is installed or the license has expired, but we are still\n within the grace period.\n- If the license requires telemetry and no telemetry data has been received in\n the past 3 days.\n\nIn both cases, a notice is triggered only if the max limit of 5 concurrent open\ntransactions is exceeded.\n\nAdditionally, notices are logged to cockroach.log at most once every 5 minutes.\nThis commit also cleans up prior logging code by utilizing log.Every() for more\nefficient log gating.\n\nThis will be backported to 24.2, 24.1, 23.2 and 23.1.\n\nEpic: CRDB-39988\nCloses CRDB-39992\nRelease note: None","shortMessageHtmlLink":"server/license: Add notice for upcoming throttling"}},{"before":"03fe9ef512bd700687b8a6e83d02fcbf64113597","after":null,"ref":"refs/heads/backport23.2-131284","pushedAt":"2024-09-26T14:21:02.000Z","pushType":"branch_deletion","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"}},{"before":null,"after":"03fe9ef512bd700687b8a6e83d02fcbf64113597","ref":"refs/heads/backport23.2-131284","pushedAt":"2024-09-26T14:18:14.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Add notice for upcoming throttling\n\nPreviously, throttling errors would only occur when active throttling was in\neffect. This update adds notices to alert clients when throttling is imminent,\nwithout disrupting running queries. A notice will be returned in the following\ncases:\n- If no license is installed or the license has expired, but we are still\n within the grace period.\n- If the license requires telemetry and no telemetry data has been received in\n the past 3 days.\n\nIn both cases, a notice is triggered only if the max limit of 5 concurrent open\ntransactions is exceeded.\n\nAdditionally, notices are logged to cockroach.log at most once every 5 minutes.\nThis commit also cleans up prior logging code by utilizing log.Every() for more\nefficient log gating.\n\nThis will be backported to 24.2, 24.1, 23.2 and 23.1.\n\nEpic: CRDB-39988\nCloses CRDB-39992\nRelease note: None","shortMessageHtmlLink":"server/license: Add notice for upcoming throttling"}},{"before":null,"after":"dbdc0920adf8f227f4666ea2b471678984be75ba","ref":"refs/heads/release-23.1","pushedAt":"2024-09-26T14:12:21.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge pull request #131259 from cockroachdb/blathers/backport-release-23.1-131022\n\nrelease-23.1: server/license: Logging and error message cleanup","shortMessageHtmlLink":"Merge pull request cockroachdb#131259 from cockroachdb/blathers/backp…"}},{"before":null,"after":"6bc1b66344700d53e1c15c8c89cf8f8e66aa41b0","ref":"refs/heads/release-23.2","pushedAt":"2024-09-26T14:11:49.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge pull request #131260 from cockroachdb/blathers/backport-release-23.2-131022\n\nrelease-23.2: server/license: Logging and error message cleanup","shortMessageHtmlLink":"Merge pull request cockroachdb#131260 from cockroachdb/blathers/backp…"}},{"before":"63e816eb6192508225186850d65116fe219c1cd3","after":"1e1910c9232791603a1435c06cb81a64f97972dd","ref":"refs/heads/release-24.1","pushedAt":"2024-09-26T14:10:39.000Z","pushType":"push","commitsCount":142,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge pull request #131261 from cockroachdb/blathers/backport-release-24.1-131022\n\nrelease-24.1: server/license: Logging and error message cleanup","shortMessageHtmlLink":"Merge pull request cockroachdb#131261 from cockroachdb/blathers/backp…"}},{"before":null,"after":"63e816eb6192508225186850d65116fe219c1cd3","ref":"refs/heads/release-24.1","pushedAt":"2024-09-26T14:10:15.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge pull request #130324 from spilchen/backport24.1-130161\n\nrelease-24.1: licenseccl: rename usage to environment","shortMessageHtmlLink":"Merge pull request cockroachdb#130324 from spilchen/backport24.1-130161"}},{"before":null,"after":"2e8c522a060ee8a52c72659534bb691faf8a6bbb","ref":"refs/heads/release-24.2","pushedAt":"2024-09-26T14:10:06.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge pull request #130952 from cockroachdb/blathers/backport-release-24.2-128935\n\nrelease-24.2: sql/sem/builtins: validate engine keys in storage builtins","shortMessageHtmlLink":"Merge pull request cockroachdb#130952 from cockroachdb/blathers/backp…"}},{"before":"6ca7c2b322443827fa9843d4bc8eca6021f8c1a2","after":"502899192194f45ac7e740ef58e8e163c84ec30a","ref":"refs/heads/issue-127014/debug-deprules","pushedAt":"2024-09-26T14:05:32.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql/schemachanger: identify which clause in a dependency rule didn’t match\n\nBefore this change, debugging why a dependency rule for the Declarative Schema\nChanger (DSC) didn’t apply was challenging. This update simplifies debugging by\nidentifying the specific clause in each rule that didn’t qualify.\n\nHere’s how the debug process works. Suppose we mistakenly swapped the `to` and\n`from` variables while checking the `TargetStatus` in this dependency rule:\n\n```\n registerDepRule(\n \"column type is changed to public after doing validation of a transient check constraint\",\n scgraph.SameStagePrecedence,\n \"transient-check-constraint\", \"column-type\",\n func(from, to NodeVars) rel.Clauses {\n colID := rel.Var(\"columnID\")\n return rel.Clauses{\n from.Type((*scpb.CheckConstraint)(nil)),\n to.Type((*scpb.ColumnType)(nil)),\n JoinOnDescID(from, to, \"table-id\"),\n to.El.AttrEqVar(screl.ColumnID, colID),\n from.ReferencedColumnIDsContains(colID),\n- from.TargetStatus(scpb.Transient),\n- to.TargetStatus(scpb.ToPublic),\n+ to.TargetStatus(scpb.Transient),\n+ from.TargetStatus(scpb.ToPublic),\n from.CurrentStatus(scpb.Status_TRANSIENT_VALIDATED),\n to.CurrentStatus(scpb.Status_PUBLIC),\n }\n },\n )\n }\n```\n\nDuring a schema change job, we might find that this rule no longer applies. To\nidentify which clause in the rule failed, enable tracing:\n\n```\nSET tracing = on;\n```\n\nRun your schema change as usual. I ran it with `EXPLAIN` to avoid executing the\njob and instead focus on building the dependency graph using the rules:\n\n```\nEXPLAIN (ddl) ALTER TABLE t1 ALTER COLUMN c1 TYPE smallint;\n```\n\nAfter completion, check the `cockroach.log` for trace information. Search for\nthe rule by name, and you’ll see entries like these:\n\n```\nI240925 15:52:36.394784 5910 sql/schemachanger/scplan/internal/rules/registry.go:59 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1131 applying dep rule \"column type is changed to public after doing validation of a transient check constraint\", 0 results found, took 25.938µs\nI240925 15:52:36.394863 5910 sql/schemachanger/scplan/internal/rules/registry.go:73 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1132 dep rule \"column type is changed to public after doing validation of a transient check constraint\" did not apply. The first unsatisfied clause is: ‹$column-type-Target[TargetStatus] = TRANSIENT_ABSENT›\n```\n\nThe first log shows no results were found by the rule, while the second log\nidentifies the specific clause that didn’t work. In this case, the clause we\nchanged is what broke the rule.\n\nSince the logic to identify failed clauses can impact performance, this\nbehavior only occurs when tracing is enabled.\n\nEpic: None\nInforms #127014\nRelease note: None","shortMessageHtmlLink":"sql/schemachanger: identify which clause in a dependency rule didn’t …"}},{"before":"1e88a4631dbb27e62a70d0f9cc37a32e19b43d8b","after":"0d7b44340f2921f129c131f74cbbafe9887685ca","ref":"refs/heads/crdb-40416/restrict-trial","pushedAt":"2024-09-26T13:51:32.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Limit enterprise trial license usage to once per cluster\n\nPreviously, clusters could install a second enterprise trial license. To\nprevent misuse, we are now restricting the use of this license type to only\nonce per cluster. This update adds the necessary tracking mechanism.\n\nA new key has been introduced in the KV system key range to record the number\nof enterprise trial licenses used, ensuring the data persists across restarts.\n\nThis change will be backported to versions 24.2, 24.1, 23.2, and 23.1.\n\nEpic: CRDB-39988\nCloses: CRDB-40416\nRelease note (general change): Attempting to install a second enterprise trial\nlicense on the same cluster will now fail.","shortMessageHtmlLink":"server/license: Limit enterprise trial license usage to once per cluster"}},{"before":null,"after":"1e88a4631dbb27e62a70d0f9cc37a32e19b43d8b","ref":"refs/heads/crdb-40416/restrict-trial","pushedAt":"2024-09-26T13:06:59.000Z","pushType":"branch_creation","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Limit enterprise trial license usage to once per cluster\n\nPreviously, clusters could install a second enterprise trial license. To\nprevent misuse, we are now restricting the use of this license type to only\nonce per cluster. This update adds the necessary tracking mechanism.\n\nA new key has been introduced in the KV system key range to record the number\nof enterprise trial licenses used, ensuring the data persists across restarts.\n\nThis change will be backported to versions 24.2, 24.1, 23.2, and 23.1.\n\nEpic: CRDB-39988\nCloses: CRDB-40416\nRelease note (general change): Attempting to install a second enterprise trial\nlicense on the same cluster will now fail.","shortMessageHtmlLink":"server/license: Limit enterprise trial license usage to once per cluster"}},{"before":"3f6373ecc49f2f91eba679fc261026d7ebd462db","after":"6ca7c2b322443827fa9843d4bc8eca6021f8c1a2","ref":"refs/heads/issue-127014/debug-deprules","pushedAt":"2024-09-26T12:08:58.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql/schemachanger: identify which clause in a dependency rule didn’t match\n\nBefore this change, debugging why a dependency rule for the Declarative Schema\nChanger (DSC) didn’t apply was challenging. This update simplifies debugging by\nidentifying the specific clause in each rule that didn’t qualify.\n\nHere’s how the debug process works. Suppose we mistakenly swapped the `to` and\n`from` variables while checking the `TargetStatus` in this dependency rule:\n\n```\n registerDepRule(\n \"column type is changed to public after doing validation of a transient check constraint\",\n scgraph.SameStagePrecedence,\n \"transient-check-constraint\", \"column-type\",\n func(from, to NodeVars) rel.Clauses {\n colID := rel.Var(\"columnID\")\n return rel.Clauses{\n from.Type((*scpb.CheckConstraint)(nil)),\n to.Type((*scpb.ColumnType)(nil)),\n JoinOnDescID(from, to, \"table-id\"),\n to.El.AttrEqVar(screl.ColumnID, colID),\n from.ReferencedColumnIDsContains(colID),\n- from.TargetStatus(scpb.Transient),\n- to.TargetStatus(scpb.ToPublic),\n+ to.TargetStatus(scpb.Transient),\n+ from.TargetStatus(scpb.ToPublic),\n from.CurrentStatus(scpb.Status_TRANSIENT_VALIDATED),\n to.CurrentStatus(scpb.Status_PUBLIC),\n }\n },\n )\n }\n```\n\nDuring a schema change job, we might find that this rule no longer applies. To\nidentify which clause in the rule failed, enable tracing:\n\n```\nSET tracing = on;\n```\n\nRun your schema change as usual. I ran it with `EXPLAIN` to avoid executing the\njob and instead focus on building the dependency graph using the rules:\n\n```\nEXPLAIN (ddl) ALTER TABLE t1 ALTER COLUMN c1 TYPE smallint;\n```\n\nAfter completion, check the `cockroach.log` for trace information. Search for\nthe rule by name, and you’ll see entries like these:\n\n```\nI240925 15:52:36.394784 5910 sql/schemachanger/scplan/internal/rules/registry.go:59 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1131 applying dep rule \"column type is changed to public after doing validation of a transient check constraint\", 0 results found, took 25.938µs\nI240925 15:52:36.394863 5910 sql/schemachanger/scplan/internal/rules/registry.go:73 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1132 dep rule \"column type is changed to public after doing validation of a transient check constraint\" did not apply. The first unsatisfied clause is: ‹$column-type-Target[TargetStatus] = TRANSIENT_ABSENT›\n```\n\nThe first log shows no results were found by the rule, while the second log\nidentifies the specific clause that didn’t work. In this case, the clause we\nchanged is what broke the rule.\n\nSince the logic to identify failed clauses can impact performance, this\nbehavior only occurs when tracing is enabled.\n\nEpic: None\nInforms #127014\nRelease note: None","shortMessageHtmlLink":"sql/schemachanger: identify which clause in a dependency rule didn’t …"}},{"before":"e5238236a48c72f0287db60e502d4aab8dbaaad1","after":"08e000634f5ccade168fc8e160eb0310d2b25426","ref":"refs/heads/master","pushedAt":"2024-09-26T00:33:50.000Z","pushType":"push","commitsCount":48,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge #129768\n\n129768: opt: propagate extra columns for lock operators r=DrewKimball a=DrewKimball\n\nA lock operator needs access to all primary key columns of the relations it locks. Therefore, all primary key columns should be propagated by a `SELECT` clause with locking even if they weren't explicitly projected. Previously, only explicitly projected columns were considered when handling a nested scope, as for a subquery. This could lead to an internal error when the lock operator did not have access to the expected columns. This commit fixes the bug by propgating all primary key columns, not just explicit ones.\r\n\r\nFixes #129647\r\n\r\nRelease note (bug fix): Fixed a bug that could cause an internal error if a table with an implicit (rowid) primary key was locked from within a subquery, like this:\r\n```\r\nSELECT * FROM (SELECT * FROM foo WHERE x = 2) FOR UPDATE;\r\n```\n\nCo-authored-by: Drew Kimball ","shortMessageHtmlLink":"Merge cockroachdb#129768"}},{"before":"12b33e5d2c45ce60bf09d42ee32e4cb6b6e0b7e7","after":"3ac4dd7f0ff2bdc23bcc147c22c19946470878c4","ref":"refs/heads/crdb-42308/set-cluster-setting-throttle","pushedAt":"2024-09-25T22:14:27.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql: Exempt SET CLUSTER SETTING from throttling\n\nThis change prevents the SET CLUSTER SETTING ... command from being\nthrottled. Previously, it was subject to throttling, but since this\ncommand is used to install a new license and disable throttling, we want\nto ensure that the action itself is not throttled. This adds an\nexception to allow license updates.\n\nThis will be backported to versions 24.2, 24.1, 23.2, and 23.1.\n\nEpic: CRDB-39988\nCloses CRDB-42308\nRelease note: None","shortMessageHtmlLink":"sql: Exempt SET CLUSTER SETTING from throttling"}},{"before":"a6c075add0f358c16d6a6f2c47db0f32d737f4ef","after":"e5238236a48c72f0287db60e502d4aab8dbaaad1","ref":"refs/heads/master","pushedAt":"2024-09-25T17:17:03.000Z","pushType":"push","commitsCount":5,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge #131108\n\n131108: kvserver: misc rac2 race conditions fixes r=sumeerbhola a=kvoli\n\nIn `ProcessPiggybackedAdmittedAtLeaderRaftMuLocked`, we swap the\r\npending updates map with another one before releasing the mutex, in\r\norder to minimize the time holding a mutex. Subsequently, the method\r\nwould then check if the updates map was empty by calling `len()`,\r\nperforming a read.\r\n\r\nWhen the updates map was not empty, the read was against a map which was\r\nnow only referenced in this function, because a new map was swapped in\r\nunder the lock.\r\n\r\nWhen the updates map was empty, the map isn't swapped out and is\r\nreferenced by the receiver struct instance, reading a ref without\r\nlocking.\r\n\r\nReturn whether the updates map was empty, to avoid racing when reading\r\nthe length of the shared ref empty map.\r\n\r\n---\r\n\r\nGoroutines can mutate the Raft node state without acquiring raftMu,\r\nhowever must acquire replica mu.\r\n\r\nAcquire a read lock on replica mu when reading the tracker progress\r\nstate from the raw node in `FollowerStateRaftMuLocked` to prevent races.\r\n\r\nPart of: #130187\r\nRelease note: None\n\nCo-authored-by: Austen McClernon ","shortMessageHtmlLink":"Merge cockroachdb#131108"}},{"before":"e9816e72d235a20e59f011d7711e98d226f55bdf","after":"3f6373ecc49f2f91eba679fc261026d7ebd462db","ref":"refs/heads/issue-127014/debug-deprules","pushedAt":"2024-09-25T16:11:00.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql/schemachanger: identify which clause in a dependency rule didn’t match\n\nBefore this change, debugging why a dependency rule for the Declarative Schema\nChanger (DSC) didn’t apply was challenging. This update simplifies debugging by\nidentifying the specific clause in each rule that didn’t qualify.\n\nHere’s how the debug process works. Suppose we mistakenly swapped the `to` and\n`from` variables while checking the `TargetStatus` in this dependency rule:\n\n```\n registerDepRule(\n \"column type is changed to public after doing validation of a transient check constraint\",\n scgraph.SameStagePrecedence,\n \"transient-check-constraint\", \"column-type\",\n func(from, to NodeVars) rel.Clauses {\n colID := rel.Var(\"columnID\")\n return rel.Clauses{\n from.Type((*scpb.CheckConstraint)(nil)),\n to.Type((*scpb.ColumnType)(nil)),\n JoinOnDescID(from, to, \"table-id\"),\n to.El.AttrEqVar(screl.ColumnID, colID),\n from.ReferencedColumnIDsContains(colID),\n- from.TargetStatus(scpb.Transient),\n- to.TargetStatus(scpb.ToPublic),\n+ to.TargetStatus(scpb.Transient),\n+ from.TargetStatus(scpb.ToPublic),\n from.CurrentStatus(scpb.Status_TRANSIENT_VALIDATED),\n to.CurrentStatus(scpb.Status_PUBLIC),\n }\n },\n )\n }\n```\n\nDuring a schema change job, we might find that this rule no longer applies. To\nidentify which clause in the rule failed, enable tracing:\n\n```\nSET tracing = on;\n```\n\nRun your schema change as usual. I ran it with `EXPLAIN` to avoid executing the\njob and instead focus on building the dependency graph using the rules:\n\n```\nEXPLAIN (ddl) ALTER TABLE t1 ALTER COLUMN c1 TYPE smallint;\n```\n\nAfter completion, check the `cockroach.log` for trace information. Search for\nthe rule by name, and you’ll see entries like these:\n\n```\nI240925 15:52:36.394784 5910 sql/schemachanger/scplan/internal/rules/registry.go:59 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1131 applying dep rule \"column type is changed to public after doing validation of a transient check constraint\", 0 results found, took 25.938µs\nI240925 15:52:36.394863 5910 sql/schemachanger/scplan/internal/rules/registry.go:73 ⋮ [T2,Vdemoapp,n1,client=127.0.0.1:53428,hostssl,user=‹demo›] 1132 dep rule \"column type is changed to public after doing validation of a transient check constraint\" did not apply. The first unsatisfied clause is: ‹$column-type-Target[TargetStatus] = TRANSIENT_ABSENT›\n```\n\nThe first log shows no results were found by the rule, while the second log\nidentifies the specific clause that didn’t work. In this case, the clause we\nchanged is what broke the rule.\n\nSince the logic to identify failed clauses can impact performance, this\nbehavior only occurs when tracing is enabled.\n\nEpic: None\nInforms #127014\nRelease note: None","shortMessageHtmlLink":"sql/schemachanger: identify which clause in a dependency rule didn’t …"}},{"before":"c7344d8506440cdfdf4e1344b3cd658c4be09b29","after":"e9816e72d235a20e59f011d7711e98d226f55bdf","ref":"refs/heads/issue-127014/debug-deprules","pushedAt":"2024-09-25T14:15:30.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Improve debugability of deprules","shortMessageHtmlLink":"Improve debugability of deprules"}},{"before":"01bc5200a62f55361889e491c2dcee9cb434c4f4","after":"101d3b9b5224d8fab8901ee4ec5b500bf1e4eeec","ref":"refs/heads/crdb-42309/reentry-start","pushedAt":"2024-09-25T14:10:36.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Initial support for serverless\n\nPreviously, the license enforcer was not initialized for secondary tenants.\nThere are two modes for secondary tenants: when the tenant runs as a separate\nprocess from the system tenant (serverless), and when it shares the same\nprocess. In the shared process mode, the enforcer relied on a shared\nsingleton—initialized for the system tenant and reused for secondary tenants.\nHowever, when the secondary tenant runs in a separate process (serverless), the\nenforcer had throttling fully disabled.\n\nThis change is the first step in supporting serverless. The main challenge in\nallowing secondary tenants to initialize the enforcer is that they don’t have\naccess to the KV key stored in the system keyspace, which records the grace\nperiod's end when no license is installed. This change doesn’t resolve that\nyet, but it sets the foundation for future work. For now, it estimates the\ngrace period by setting it to 7 days from the time the enforcer is created.\n\nSeveral changes were made to support serverless in this form:\n- Call the enforcer’s `Start()` function for secondary tenants as well.\n- Allow `Start()` to be called multiple times.\n- Move all parameters for `Start` into an options struct.\n- Remove the enforcer singleton, as it caused more issues (especially in tests)\n than benefits.\n- Secondary tenants that share the same process will still share the same\n enforcer, but now the enforcer is passed around by storing a copy in\n `SQLConfig`.\n\nEpic: CRDB-39988\nInforms: CRDB-42309\nRelease note: None","shortMessageHtmlLink":"server/license: Initial support for serverless"}},{"before":"f3470f25ef16b31526a514a00b90c8fc5dbc44ba","after":"01bc5200a62f55361889e491c2dcee9cb434c4f4","ref":"refs/heads/crdb-42309/reentry-start","pushedAt":"2024-09-25T12:22:55.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Initial support for serverless\n\nPreviously, the license enforcer was not initialized for secondary tenants.\nThere are two modes for secondary tenants: when the tenant runs as a separate\nprocess from the system tenant (serverless), and when it shares the same\nprocess. In the shared process mode, the enforcer relied on a shared\nsingleton—initialized for the system tenant and reused for secondary tenants.\nHowever, when the secondary tenant runs in a separate process (serverless), the\nenforcer had throttling fully disabled.\n\nThis change is the first step in supporting serverless. The main challenge in\nallowing secondary tenants to initialize the enforcer is that they don’t have\naccess to the KV key stored in the system keyspace, which records the grace\nperiod's end when no license is installed. This change doesn’t resolve that\nyet, but it sets the foundation for future work. For now, it estimates the\ngrace period by setting it to 7 days from the time the enforcer is created.\n\nSeveral changes were made to support serverless in this form:\n- Call the enforcer’s `Start()` function for secondary tenants as well.\n- Allow `Start()` to be called multiple times.\n- Move all parameters for `Start` into an options struct.\n- Remove the enforcer singleton, as it caused more issues (especially in tests)\n than benefits.\n- Secondary tenants that share the same process will still share the same\n enforcer, but now the enforcer is passed around by storing a copy in\n `SQLConfig`.\n\nEpic: CRDB-39988\nInforms: CRDB-42309\nRelease note: None","shortMessageHtmlLink":"server/license: Initial support for serverless"}},{"before":"aba4cd94ed872224a8c7e7b63616db4c5b1b7440","after":"f3470f25ef16b31526a514a00b90c8fc5dbc44ba","ref":"refs/heads/crdb-42309/reentry-start","pushedAt":"2024-09-25T12:03:42.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Initial support for serverless\n\nPreviously, the license enforcer was not initialized for secondary tenants.\nThere are two modes for secondary tenants: when the tenant runs as a separate\nprocess from the system tenant (serverless), and when it shares the same\nprocess. In the shared process mode, the enforcer relied on a shared\nsingleton—initialized for the system tenant and reused for secondary tenants.\nHowever, when the secondary tenant runs in a separate process (serverless), the\nenforcer had throttling fully disabled.\n\nThis change is the first step in supporting serverless. The main challenge in\nallowing secondary tenants to initialize the enforcer is that they don’t have\naccess to the KV key stored in the system keyspace, which records the grace\nperiod's end when no license is installed. This change doesn’t resolve that\nyet, but it sets the foundation for future work. For now, it estimates the\ngrace period by setting it to 7 days from the time the enforcer is created.\n\nSeveral changes were made to support serverless in this form:\n- Call the enforcer’s `Start()` function for secondary tenants as well.\n- Allow `Start()` to be called multiple times.\n- Move all parameters for `Start` into an options struct.\n- Remove the enforcer singleton, as it caused more issues (especially in tests)\n than benefits.\n- Secondary tenants that share the same process will still share the same\n enforcer, but now the enforcer is passed around by storing a copy in\n `SQLConfig`.\n\nEpic: CRDB-39988\nInforms: CRDB-42309\nRelease note: None","shortMessageHtmlLink":"server/license: Initial support for serverless"}},{"before":"c5e9b2212ac14cd295bf4fb7310832515c6bbd02","after":"a6c075add0f358c16d6a6f2c47db0f32d737f4ef","ref":"refs/heads/master","pushedAt":"2024-09-25T12:01:31.000Z","pushType":"push","commitsCount":37,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"Merge #131177\n\n131177: cli: improve tsdump datadog upload r=aa-joshi a=aa-joshi\n\nPreviously, tsdump datadog upload was time consuming. This was due to synchronous upload requests to datadog. Along with this, we were decoding raw data to TimeSeriesData. Then again converting it to DatadogSeries. This change addresse both challenges. We are now decoding timeseries data to DatadogSeries. We have decoupled deocding & uploading data so that we will perform both operations concurrently.\r\n\r\nEpic: CC-27740\r\nRelease note: None\n\nCo-authored-by: Akshay Joshi ","shortMessageHtmlLink":"Merge cockroachdb#131177"}},{"before":"9b5db4539ebc23670f5ecc16ddc3abf2dcf21e45","after":"aba4cd94ed872224a8c7e7b63616db4c5b1b7440","ref":"refs/heads/crdb-42309/reentry-start","pushedAt":"2024-09-25T12:01:01.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"server/license: Initial support for serverless\n\nPreviously, the license enforcer was not initialized for secondary tenants.\nThere are two modes for secondary tenants: when the tenant runs as a separate\nprocess from the system tenant (serverless), and when it shares the same\nprocess. In the shared process mode, the enforcer relied on a shared\nsingleton—initialized for the system tenant and reused for secondary tenants.\nHowever, when the secondary tenant runs in a separate process (serverless), the\nenforcer had throttling fully disabled.\n\nThis change is the first step in supporting serverless. The main challenge in\nallowing secondary tenants to initialize the enforcer is that they don’t have\naccess to the KV key stored in the system keyspace, which records the grace\nperiod's end when no license is installed. This change doesn’t resolve that\nyet, but it sets the foundation for future work. For now, it estimates the\ngrace period by setting it to 7 days from the time the enforcer is created.\n\nSeveral changes were made to support serverless in this form:\n- Call the enforcer’s `Start()` function for secondary tenants as well.\n- Allow `Start()` to be called multiple times.\n- Move all parameters for `Start` into an options struct.\n- Remove the enforcer singleton, as it caused more issues (especially in tests)\n than benefits.\n- Secondary tenants that share the same process will still share the same\n enforcer, but now the enforcer is passed around by storing a copy in\n `SQLConfig`.\n\nEpic: CRDB-39988\nInforms: CRDB-42309\nRelease note: None","shortMessageHtmlLink":"server/license: Initial support for serverless"}},{"before":"2975eebe5d062584afb6caf985f75d05aacebd1d","after":null,"ref":"refs/heads/crdb-39992/throttle-warning-stacked","pushedAt":"2024-09-25T11:58:15.000Z","pushType":"branch_deletion","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"}},{"before":"71fdab3c7d526bade1af7a44b86573d9985ce982","after":null,"ref":"refs/heads/issue-130756/create-view-issue","pushedAt":"2024-09-25T10:47:09.000Z","pushType":"branch_deletion","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"}},{"before":"8d9466cef33d312ea368f175bc8d9089bc535a51","after":"12b33e5d2c45ce60bf09d42ee32e4cb6b6e0b7e7","ref":"refs/heads/crdb-42308/set-cluster-setting-throttle","pushedAt":"2024-09-24T18:31:57.000Z","pushType":"force_push","commitsCount":0,"pusher":{"login":"spilchen","name":null,"path":"/spilchen","primaryAvatarUrl":"https://avatars.githubusercontent.com/u/171762?s=80&v=4"},"commit":{"message":"sql: Exempt SET CLUSTER SETTING from throttling\n\nThis change prevents the SET CLUSTER SETTING ... command from being\nthrottled. Previously, it was subject to throttling, but since this\ncommand is used to install a new license and disable throttling, we want\nto ensure that the action itself is not throttled. This adds an\nexception to allow license updates.\n\nThis will be backported to versions 24.2, 24.1, 23.2, and 23.1.\n\nEpic: CRDB-39988\nCloses CRDB-42308\nRelease note: None","shortMessageHtmlLink":"sql: Exempt SET CLUSTER SETTING from throttling"}}],"hasNextPage":true,"hasPreviousPage":false,"activityType":"all","actor":null,"timePeriod":"all","sort":"DESC","perPage":30,"startCursor":"Y3Vyc29yOnYyOpK7MjAyNC0wOS0yN1QxOToyMDoxMC4wMDAwMDBazwAAAATC81l-","endCursor":"Y3Vyc29yOnYyOpK7MjAyNC0wOS0yNFQxODozMTo1Ny4wMDAwMDBazwAAAAS_gMaT"}},"title":"Activity · spilchen/cockroach"}