Skip to content

Commit

Permalink
Merge branch 'main' into DOC-9808
Browse files Browse the repository at this point in the history
  • Loading branch information
mdlinville authored Jun 11, 2024
2 parents b1123fe + 9f82bc6 commit ae0c391
Show file tree
Hide file tree
Showing 2 changed files with 155 additions and 0 deletions.
34 changes: 34 additions & 0 deletions src/current/_data/releases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6124,3 +6124,37 @@
docker_arm_limited_access: false
source: true
previous_release: v23.1.21

- release_name: v23.2.6
major_version: v23.2
release_date: '2024-06-11'
release_type: Production
go_version: go1.22.0
sha: 212dffab088f28ff592219b98869bc34f8691ecc
has_sql_only: true
has_sha256sum: true
mac:
mac_arm: true
mac_arm_experimental: true
mac_arm_limited_access: false
windows: true
linux:
linux_arm: true
linux_arm_experimental: false
linux_arm_limited_access: false
linux_intel_fips: true
linux_arm_fips: false
docker:
docker_image: cockroachdb/cockroach
docker_arm: true
docker_arm_experimental: false
docker_arm_limited_access: false
source: true
previous_release: v23.2.5
cloud_only: true
cloud_only_message_short: 'Available only for select CockroachDB Cloud clusters'
cloud_only_message: >
This version is currently available only for select
CockroachDB Cloud clusters. To request to upgrade
a CockroachDB self-hosted cluster to this version,
[contact support](https://support.cockroachlabs.com/hc/en-us/requests/new).
121 changes: 121 additions & 0 deletions src/current/_includes/releases/v23.2/v23.2.6.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
## v23.2.6

Release Date: June 11, 2024

{% include releases/new-release-downloads-docker-image.md release=include.release %}

<h3 id="v23-2-6-{{-site.data.products.enterprise-}}-edition-changes">{{ site.data.products.enterprise }} edition changes</h3>

- Fixed a bug that was present since v22.2 where [changefeeds]({% link v23.2/change-data-capture-overview.md %}) with long-running [initial scans]({% link v23.2/create-changefeed.md %}#initial-scan) might incorrectly restore checkpoint job progress and drop events during [changefeed restarts]({% link v23.2/changefeed-messages.md %}#duplicate-messages) due to transient errors or node restarts. The bug was most likely to occur in clusters with the following contributing factors:
- The `changefeed.shutdown_checkpoint.enabled` [cluster setting]({% link v23.2/cluster-settings.md %}) was enabled.
- The cluster settings `changefeed.frontier_checkpoint_frequency` and `low changefeed.frontier_highwater_lag_checkpoint_threshold` were set low, which resulted in the initial scan taking many multiples of the configured frequency to complete.
- There were multiple target tables with significant differences in row counts in one changefeed.
- The changefeed target tables were large with many ranges.
- The initial scan took a long time to complete (an hour or longer). [#123966][#123966]

<h3 id="v23-2-6-sql-language-changes">SQL language changes</h3>

- Updated the [`SHOW GRANTS`]({% link v23.2/show-grants.md %}) responses to display the `object_type` and `object_name`, which has replaced the `relation_name` column. [#122822][#122822]
- Added [external connection]({% link v23.2/create-external-connection.md %}) granted privileges to the [`SHOW GRANTS`]({% link v23.2/show-grants.md %}) command. [#122822][#122822]
- Introduced three new [cluster settings]({% link v23.2/cluster-settings.md %}) for controlling table statistics forecasting:
- [`sql.stats.forecasts.min_observations`]({% link v23.2/cluster-settings.md %}) is the minimum number of observed statistics required to produce a forecast.
- [`sql.stats.forecasts.min_goodness_of_fit`]({% link v23.2/cluster-settings.md %}) is the minimum R² (goodness of fit) measurement required from all predictive models to use a forecast.
- [`sql.stats.forecasts.max_decrease`]({% link v23.2/cluster-settings.md %}) is the most a prediction can decrease, expressed as the minimum ratio of the prediction to the lowest prior observation. [#122458][#122458]
- Added a new [session setting]({% link v23.2/session-variables.md %}) `optimizer_use_improved_multi_column_selectivity_estimate`, which if enabled, causes the [optimizer]({% link v23.2/cost-based-optimizer.md %}) to use an improved selectivity estimate for multi-column predicates. This setting will default to `true` on v24.2 and later, and `false` on earlier versions. [#123100][#123100]
- The [optimizer]({% link v23.2/cost-based-optimizer.md %}) can now plan constrained scans over partial indexes in more cases, particularly on [partial indexes]({% link v23.2/partial-indexes.md %}) with predicates referencing [virtual computed columns]({% link v23.2/computed-columns.md %}). [#123469][#123469]
- The row-level TTL setting [`ttl_delete_rate_limit`]({% link v23.2/row-level-ttl.md %}) is now set to `100` by default, which sets the rate limit for deleting expired rows to `100`. [#124353][#124353]

<h3 id="v23-2-6-operational-changes">Operational changes</h3>

- Two new metrics track the status of the SQL Activity Update job, which pre-aggregates top K information within the SQL statistics subsytem and writes the results to `system.statement_activity` and `system.transaction_activity`:
- `sql.stats.activity.updates.successful`: Number of successful updates made by the SQL activity updater job.
- `sql.stats.activity.update.latency`: The latency of updates made by the SQL activity updater job. Includes failed update attempts. [#123960][#123960]
- Added a new counter [metric]({% link v23.2/metrics.md %}), `sql.stats.flush.done_signals.ignored`, that tracks the number of times the SQL activity update job has ignored the signal that indicates that a flush has completed. This metric may indicate that the SQL activity update job is taking longer than expected to complete. [#123960][#123960]
- Added a new counter [metric]({% link v23.2/metrics.md %}), `sql.stats.activity.updates.failed`, to measure the number of update attempts made by the SQL activity update job that failed with errors. The SQL activity update job is used to pre-aggregate top K information within the SQL stats subsystem and write the results to `system.statement_activity` and `system.transaction_activity`. [#123960][#123960]
- Added a new counter [metric]({% link v23.2/metrics.md %}), `sql.stats.flush.fingerprint.count`, that tracks the number of unique statement and transaction fingerprints included in the SQL stats flush. [#123960][#123960]
- Added the `sql.pgwire.pipeline.count` [metric]({% link v23.2/metrics.md %}), which measures how many wire protocol commands have been received by the server, but have not yet started processing. This metric will only grow if clients are using the [pipeline mode](https://www.postgresql.org/docs/current/libpq-pipeline-mode.html) of the PostgreSQL wire protocol. [#124260][#124260]
- The `client_authentication_ok` and `client_session_end` events are now logged to the [`SESSIONS` log channel]({% link v23.2/logging-use-cases.md %}#sessions) unconditionally. Previously, these would only be logged if the `server.auth_log.sql_sessions.enabled` [cluster setting]({% link v23.2/cluster-settings.md %}) was set to `true`. All other `SESSIONS` log messages are still only logged if `server.auth_log.sql_sessions.enabled` or `server.auth_log.sql_connections.enabled` are set to `true`. To not show `client_authentication_ok` and `client_session_end` events, disable the `SESSIONS` log channel entirely. [#124374][#124374]

<h3 id="v23-2-6-db-console-changes">DB Console changes</h3>

- The [**Database**]({% link v23.2/ui-databases-page.md %}) details and **Table** details pages now display the correct stats in the **Table Stats Last Updated**. [#122815][#122815]
- Viewing the [**SQL Activity**]({% link v23.2/ui-statements-page.md %}#active-executions-view) sorted by `% of Runtime` now correctly sorts entries by the runtime amount. [#123901][#123901]

<h3 id="v23-2-6-bug-fixes">Bug fixes</h3>

- Fixed a bug where [client certificate authentication]({% link v23.2/authentication.md %}#client-authentication) combined with [identity maps]({% link v23.2/sso-sql.md %}#identity-map-configuration) (`server.identity_map.configuration`) did not work. For the feature to work correctly, the client must specify a valid database user in the [connection string]({% link v23.2/connection-parameters.md %}). [#122749][#122749]
- Fixed a bug where the [row-based execution engine]({% link v23.2/architecture/sql-layer.md %}#query-execution) could drop a [`LIMIT`]({% link v23.2/limit-offset.md %}) clause when there was an [`ORDER BY`]({% link v23.2/order-by.md %}) clause, and the ordering was partially provided by an input operator. For example, this bug could occur with an ordering such as `ORDER BY a, b` when the scanned index was only ordered on column `a`. The impact of this bug was that more rows may have been returned than specified by the `LIMIT` clause. This bug is only present when not using the [vectorized execution engine]({% link v23.2/architecture/sql-layer.md %}#vectorized-query-execution); that is, when running with `SET vectorize = off;`. This bug has existed since CockroachDB v22.1. [#122836][#122836]
- Fixed a bug in the DB Console's [**Custom Chart**]({% link v23.2/ui-custom-chart-debug-page.md %}) tool where store-level metrics were displayed only for the first store ID associated with the node. Now data is displayed for all stores present on a node, and a single time series is shown for each store, rather than an aggregated value for all of the node's stores. This allows finer-grained monitoring of store-level metrics. [#122703][#122703]
- Fixed a bug where privileges granted for [external connections]({% link v23.2/create-external-connection.md %}) were incorrectly showing up in [`SHOW SYSTEM GRANTS`]({% link v23.2/show-system-grants.md %}), but were not useful because there was no associated object name. The privileges no longer appear in `SHOW SYSTEM GRANTS`. Instead, the `SHOW GRANTS ON EXTERNAL CONNECTION` statement should be used. [#122905][#122905]
- Statistics forecasts of zero rows can cause suboptimal [query plans]({% link v23.2/cost-based-optimizer.md %}). Forecasting will now avoid predicting zero rows for most downward-trending statistics. [#122458][#122458]
- Fixed a bug introduced in v23.2 that could cause a [PL/pgSQL]({% link v23.2/plpgsql.md %}) routine to return incorrect results when the routine included:
- At least one parameter.
- An `IF` statement with one leak-proof branch and one branch with side effects. [#120742][#120742]
- Fixed a bug that could result in an internal error when attempting to create a [PL/pgSQL]({% link v23.2/plpgsql.md %}) routine using the (currently unsupported) `%ROWTYPE` syntax for a variable declaration. [#123010][#123010]
- Fixed a bug where a [`RESTORE`]({% link v23.2/restore.md %}) of a backup that itself contained a table created by the `RESTORE` of a table with an in-progress [`IMPORT INTO`]({% link v23.2/import-into.md %}) would fail to restore all rows. [#120543][#120543]
- Fixed a bug introduced in v23.2 that could cause a [PL/pgSQL]({% link v23.2/plpgsql.md %}) variable assignment to not be executed if the variable was never referenced after the assignment. [#123116][#123116]
- Fixed a bug where CockroachDB could run into an `attempting to append refresh spans after the tracked timestamp has moved forward` internal error in some edge cases. The bug had been present since v22.2. [#123150][#123150]
- A [job]({% link v23.2/show-jobs.md %}) will now log rather than fail if it reports an out-of-bound progress fraction. [#122964][#122964]
- Fixed a bug that would occur when [`ALTER TYPE ... DROP VALUE`]({% link v23.2/alter-type.md %}) is followed by [`DROP SCHEMA CASCADE ...`]({% link v23.2/drop-schema.md %}) in the same transaction. Previously, the `ALTER TYPE` schema change would get queued up to run at commit time, but by that point, the type may have already been removed, so the commit could fail. [#123576][#123576]
- Fixed a bug that could lead to descriptors with self references that pointed to incorrect descriptor IDs. Now, tables that see the error `invalid inbound foreign key ... origin table ID should be` or `invalid outbound foreign key ... reference table ID should be` will automatically repair post deserialization. [#123681][#123681]
- Fixed a bug where a failed [restore]({% link v23.2/restore.md %}) job could leave the system in a state where re-attempting the restore was not possible without manual intervention. [#123463][#123463]
- [Index recommendations]({% link v23.2/ui-databases-page.md %}#index-recommendations) in the [DB Console]({% link v23.2/ui-overview.md %}) will now function properly for indexes on tables or columns whose names contain quotation marks or whitespace. For example: `CREATE INDEX ON "my table" ("my col");`. [#122119][#122119]
- Fixed a crash introduced in v23.2.5 that could occur when planning [statistics collection]({% link v23.2/cost-based-optimizer.md %}#enable-and-disable-automatic-statistics-collection-for-clusters) on a table with a [virtual computed column]({% link v23.2/computed-columns.md %}) using a user-defined type when the newly introduced [cluster setting]({% link v23.2/cluster-settings.md %}) `sql.stats.virtual_computed_columns.enabled` is set to `true`. (The setting was introduced in v23.2.4 and set to `false` by default.) [#124080][#124080]
- Added automated clean up and validation for [dropped roles]({% link v23.2/drop-role.md %}) inside descriptors. [#124670][#124670]
- Fixed a bug where [`DROP ROLE`]({% link v23.2/drop-role.md %}) and [`DROP USER`]({% link v23.2/drop-user.md %}) could leave references behind inside types, which could prevent [`SHOW GRANTS`]({% link v23.2/show-grants.md %}) from working. [#124668][#124668]
- Fixed a bug where a change to a [user-defined type]({% link v23.2/create-type.md %}) could cause queries against tables using that type to fail with the error `histogram.go:694: span must be fully contained in the bucket`. The change to the user-defined type could come directly from an [`ALTER TYPE`]({% link v23.2/alter-type.md %}) statement, or indirectly from an [`ALTER DATABASE ADD REGION`]({% link v23.2/alter-database.md %}#add-region) or [`DROP REGION`]({% link v23.2/alter-database.md %}#drop-region) statement (which implicitly change the `crdb_internal_region` type). This was present since user-defined types were introduced in v20.2. [#124854][#124854]

<h3 id="v23-2-6-performance-improvements">Performance improvements</h3>

- More efficient [query plans]({% link v23.2/cost-based-optimizer.md %}) are now generated for queries with text similarity filters, for example, `text_col % 'foobar'`. These plans are generated if the `optimizer_use_trigram_similarity_optimization` [session setting]({% link v23.2/session-variables.md %}) is enabled. It is disabled by default. [#122753][#122753]
- The [optimizer]({% link v23.2/cost-based-optimizer.md %}) now costs [`distinct-on`]({% link v23.2/select-clause.md %}#eliminate-duplicate-rows) operators more accurately. It may produce more efficient query plans in some cases. [#122844][#122844]
- Added a new [session setting]({% link v23.2/session-variables.md %}) `optimizer_use_improved_zigzag_join_costing`. When enabled and when the [cluster setting]({% link v23.2/cluster-settings.md %}) `enable_zigzag_join` is also enabled, the cost of zigzag joins is updated such that a zigzag join will be chosen over a scan only if it produces fewer rows than a scan. [#123100][#123100]
- Improved the selectivity estimation of multi-column filters when the multi-column distinct count is high. This prevents the [optimizer]({% link v23.2/cost-based-optimizer.md %}) from choosing a bad query plan due to over-estimating the selectivity of a multi-column predicate. [#123100][#123100]
- Improved the efficiency of error handling in the [vectorized execution engine]({% link v23.2/vectorized-execution.md %}) to reduce the CPU overhead of statement timeout handling and reduce the potential for more statement timeouts. [#123502][#123502]

<div class="release-note-contributors" markdown="1">

<h3 id="v23-2-6-contributors">Contributors</h3>

This release includes 115 merged PRs by 32 authors.

</div>

[#120543]: https://github.com/cockroachdb/cockroach/pull/120543
[#120742]: https://github.com/cockroachdb/cockroach/pull/120742
[#122119]: https://github.com/cockroachdb/cockroach/pull/122119
[#122458]: https://github.com/cockroachdb/cockroach/pull/122458
[#122703]: https://github.com/cockroachdb/cockroach/pull/122703
[#122749]: https://github.com/cockroachdb/cockroach/pull/122749
[#122753]: https://github.com/cockroachdb/cockroach/pull/122753
[#122815]: https://github.com/cockroachdb/cockroach/pull/122815
[#122822]: https://github.com/cockroachdb/cockroach/pull/122822
[#122836]: https://github.com/cockroachdb/cockroach/pull/122836
[#122844]: https://github.com/cockroachdb/cockroach/pull/122844
[#122905]: https://github.com/cockroachdb/cockroach/pull/122905
[#122964]: https://github.com/cockroachdb/cockroach/pull/122964
[#123010]: https://github.com/cockroachdb/cockroach/pull/123010
[#123067]: https://github.com/cockroachdb/cockroach/pull/123067
[#123100]: https://github.com/cockroachdb/cockroach/pull/123100
[#123116]: https://github.com/cockroachdb/cockroach/pull/123116
[#123150]: https://github.com/cockroachdb/cockroach/pull/123150
[#123374]: https://github.com/cockroachdb/cockroach/pull/123374
[#123463]: https://github.com/cockroachdb/cockroach/pull/123463
[#123469]: https://github.com/cockroachdb/cockroach/pull/123469
[#123502]: https://github.com/cockroachdb/cockroach/pull/123502
[#123576]: https://github.com/cockroachdb/cockroach/pull/123576
[#123594]: https://github.com/cockroachdb/cockroach/pull/123594
[#123681]: https://github.com/cockroachdb/cockroach/pull/123681
[#123901]: https://github.com/cockroachdb/cockroach/pull/123901
[#123960]: https://github.com/cockroachdb/cockroach/pull/123960
[#123966]: https://github.com/cockroachdb/cockroach/pull/123966
[#124071]: https://github.com/cockroachdb/cockroach/pull/124071
[#124080]: https://github.com/cockroachdb/cockroach/pull/124080
[#124083]: https://github.com/cockroachdb/cockroach/pull/124083
[#124260]: https://github.com/cockroachdb/cockroach/pull/124260
[#124298]: https://github.com/cockroachdb/cockroach/pull/124298
[#124353]: https://github.com/cockroachdb/cockroach/pull/124353
[#124374]: https://github.com/cockroachdb/cockroach/pull/124374
[#124668]: https://github.com/cockroachdb/cockroach/pull/124668
[#124670]: https://github.com/cockroachdb/cockroach/pull/124670
[#124854]: https://github.com/cockroachdb/cockroach/pull/124854

0 comments on commit ae0c391

Please sign in to comment.