Skip to content

Commit 1de9c4b

Browse files
authored
Merge pull request #155561 from mw5h/backportrelease-25.4-155536
release-25.4: vecindex: enable vector indexing by default
2 parents 00809c0 + 97cae17 commit 1de9c4b

File tree

12 files changed

+23
-73
lines changed

12 files changed

+23
-73
lines changed

docs/generated/settings/settings-for-tenants.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ feature.infer_rbr_region_col_using_constraint.enabled boolean false set to true
7777
feature.restore.enabled boolean true set to true to enable restore, false to disable; default is true application
7878
feature.schema_change.enabled boolean true set to true to enable schema changes, false to disable; default is true application
7979
feature.stats.enabled boolean true set to true to enable CREATE STATISTICS/ANALYZE, false to disable; default is true application
80-
feature.vector_index.enabled boolean false set to true to enable vector indexes, false to disable; default is false application
80+
feature.vector_index.enabled boolean true set to true to enable vector indexes, false to disable; default is true application
8181
jobs.retention_time duration 336h0m0s the amount of time for which records for completed jobs are retained application
8282
kv.bulk_sst.target_size byte size 16 MiB target size for SSTs emitted from export requests; export requests (i.e. BACKUP) may buffer up to the sum of kv.bulk_sst.target_size and kv.bulk_sst.max_allowed_overage in memory system-visible
8383
kv.closed_timestamp.follower_reads.enabled (alias: kv.closed_timestamp.follower_reads_enabled) boolean true allow (all) replicas to serve consistent historical reads based on closed timestamp information system-visible

docs/generated/settings/settings.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@
8282
<tr><td><div id="setting-feature-restore-enabled" class="anchored"><code>feature.restore.enabled</code></div></td><td>boolean</td><td><code>true</code></td><td>set to true to enable restore, false to disable; default is true</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
8383
<tr><td><div id="setting-feature-schema-change-enabled" class="anchored"><code>feature.schema_change.enabled</code></div></td><td>boolean</td><td><code>true</code></td><td>set to true to enable schema changes, false to disable; default is true</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
8484
<tr><td><div id="setting-feature-stats-enabled" class="anchored"><code>feature.stats.enabled</code></div></td><td>boolean</td><td><code>true</code></td><td>set to true to enable CREATE STATISTICS/ANALYZE, false to disable; default is true</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
85-
<tr><td><div id="setting-feature-vector-index-enabled" class="anchored"><code>feature.vector_index.enabled</code></div></td><td>boolean</td><td><code>false</code></td><td>set to true to enable vector indexes, false to disable; default is false</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
85+
<tr><td><div id="setting-feature-vector-index-enabled" class="anchored"><code>feature.vector_index.enabled</code></div></td><td>boolean</td><td><code>true</code></td><td>set to true to enable vector indexes, false to disable; default is true</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
8686
<tr><td><div id="setting-jobs-retention-time" class="anchored"><code>jobs.retention_time</code></div></td><td>duration</td><td><code>336h0m0s</code></td><td>the amount of time for which records for completed jobs are retained</td><td>Basic/Standard/Advanced/Self-Hosted</td></tr>
8787
<tr><td><div id="setting-kv-allocator-lease-rebalance-threshold" class="anchored"><code>kv.allocator.lease_rebalance_threshold</code></div></td><td>float</td><td><code>0.05</code></td><td>minimum fraction away from the mean a store&#39;s lease count can be before it is considered for lease-transfers</td><td>Advanced/Self-Hosted</td></tr>
8888
<tr><td><div id="setting-kv-allocator-load-based-lease-rebalancing-enabled" class="anchored"><code>kv.allocator.load_based_lease_rebalancing.enabled</code></div></td><td>boolean</td><td><code>true</code></td><td>set to enable rebalancing of range leases based on load and latency</td><td>Advanced/Self-Hosted</td></tr>

pkg/sql/backfill/backfill_test.go

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ func TestVectorColumnAndIndexBackfill(t *testing.T) {
5151
defer srv.Stopper().Stop(ctx)
5252
sqlDB := sqlutils.MakeSQLRunner(db)
5353

54-
// Enable vector indexes.
55-
sqlDB.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
56-
5754
// Create a table with a vector column
5855
sqlDB.Exec(t, `
5956
CREATE TABLE vectors (
@@ -118,9 +115,6 @@ func TestConcurrentOperationsDuringVectorIndexCreation(t *testing.T) {
118115
defer srv.Stopper().Stop(ctx)
119116
sqlDB := sqlutils.MakeSQLRunner(db)
120117

121-
// Enable vector indexes.
122-
sqlDB.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
123-
124118
// Create a table with a vector column
125119
sqlDB.Exec(t, `
126120
CREATE TABLE vectors (
@@ -203,9 +197,6 @@ func TestVectorIndexWithPrefixBackfill(t *testing.T) {
203197
defer srv.Stopper().Stop(ctx)
204198
sqlDB := sqlutils.MakeSQLRunner(db)
205199

206-
// Enable vector indexes.
207-
sqlDB.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
208-
209200
// Create a table with a vector column + a prefix column.
210201
sqlDB.Exec(t, `
211202
CREATE TABLE items (
@@ -275,9 +266,6 @@ func TestVectorIndexMergingDuringBackfill(t *testing.T) {
275266
defer srv.Stopper().Stop(ctx)
276267
sqlDB := sqlutils.MakeSQLRunner(db)
277268

278-
// Enable vector indexes.
279-
sqlDB.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
280-
281269
// Enable deterministic vector index fixups for consistent testing.
282270
sqlDB.Exec(t, `SET CLUSTER SETTING sql.vecindex.deterministic_fixups.enabled = true`)
283271

@@ -370,9 +358,6 @@ func TestVectorIndexMergingDuringBackfillWithPrefix(t *testing.T) {
370358
defer srv.Stopper().Stop(ctx)
371359
sqlDB := sqlutils.MakeSQLRunner(db)
372360

373-
// Enable vector indexes.
374-
sqlDB.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
375-
376361
// Enable deterministic vector index fixups for consistent testing.
377362
sqlDB.Exec(t, `SET CLUSTER SETTING sql.vecindex.deterministic_fixups.enabled = true`)
378363

pkg/sql/catalog/tabledesc/index_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ func TestIndexInterface(t *testing.T) {
5151
}
5252
runner := sqlutils.MakeSQLRunner(conn)
5353

54-
// Enable vector indexes.
55-
runner.Exec(t, `SET CLUSTER SETTING feature.vector_index.enabled = true`)
56-
5754
runner.Exec(t, `
5855
CREATE TABLE d.t (
5956
c1 INT,

pkg/sql/logictest/logic.go

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1876,14 +1876,6 @@ func (t *logicTest) newCluster(
18761876
}
18771877
}
18781878

1879-
// Enable vector indexes by default for tests.
1880-
// TODO(andyk): Remove this once vector indexes are enabled by default.
1881-
if _, err := conn.Exec(
1882-
"SET CLUSTER SETTING feature.vector_index.enabled = true",
1883-
); err != nil {
1884-
t.Fatal(err)
1885-
}
1886-
18871879
// Ensure that vector index background operations are deterministic, so
18881880
// that tests don't flake.
18891881
if _, err := conn.Exec(

pkg/sql/logictest/testdata/logic_test/event_log

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,6 @@ ORDER BY "timestamp", info
492492
----
493493
1 {"ApplicationName": "$ internal-optInToDiagnosticsStatReporting", "DefaultValue": "true", "EventType": "set_cluster_setting", "SettingName": "diagnostics.reporting.enabled", "Statement": "SET CLUSTER SETTING \"diagnostics.reporting.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "node", "Value": "true"}
494494
1 {"DefaultValue": "-10s", "EventType": "set_cluster_setting", "SettingName": "sql.crdb_internal.table_row_statistics.as_of_time", "Statement": "SET CLUSTER SETTING \"sql.crdb_internal.table_row_statistics.as_of_time\" = e'-1\\u00B5s'", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "-00:00:00.000001"}
495-
1 {"DefaultValue": "false", "EventType": "set_cluster_setting", "SettingName": "feature.vector_index.enabled", "Statement": "SET CLUSTER SETTING \"feature.vector_index.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "true"}
496495
1 {"DefaultValue": "false", "EventType": "set_cluster_setting", "SettingName": "sql.vecindex.deterministic_fixups.enabled", "Statement": "SET CLUSTER SETTING \"sql.vecindex.deterministic_fixups.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "true"}
497496
1 {"DefaultValue": "true", "EventType": "set_cluster_setting", "SettingName": "kv.allocator.load_based_lease_rebalancing.enabled", "Statement": "SET CLUSTER SETTING \"kv.allocator.load_based_lease_rebalancing.enabled\" = false", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "false"}
498497
1 {"DefaultValue": "true", "EventType": "set_cluster_setting", "SettingName": "kv.allocator.load_based_lease_rebalancing.enabled", "Statement": "SET CLUSTER SETTING \"kv.allocator.load_based_lease_rebalancing.enabled\" = DEFAULT", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "DEFAULT"}
@@ -513,7 +512,6 @@ ORDER BY "timestamp", info
513512
----
514513
1 {"ApplicationName": "$ internal-optInToDiagnosticsStatReporting", "DefaultValue": "true", "EventType": "set_cluster_setting", "SettingName": "diagnostics.reporting.enabled", "Statement": "SET CLUSTER SETTING \"diagnostics.reporting.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "node", "Value": "true"}
515514
1 {"DefaultValue": "-10s", "EventType": "set_cluster_setting", "SettingName": "sql.crdb_internal.table_row_statistics.as_of_time", "Statement": "SET CLUSTER SETTING \"sql.crdb_internal.table_row_statistics.as_of_time\" = e'-1\\u00B5s'", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "-00:00:00.000001"}
516-
1 {"DefaultValue": "false", "EventType": "set_cluster_setting", "SettingName": "feature.vector_index.enabled", "Statement": "SET CLUSTER SETTING \"feature.vector_index.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "true"}
517515
1 {"DefaultValue": "false", "EventType": "set_cluster_setting", "SettingName": "sql.vecindex.deterministic_fixups.enabled", "Statement": "SET CLUSTER SETTING \"sql.vecindex.deterministic_fixups.enabled\" = true", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "true"}
518516
1 {"EventType": "set_cluster_setting", "PlaceholderValues": ["'some string'"], "SettingName": "cluster.label", "Statement": "SET CLUSTER SETTING \"cluster.label\" = $1", "Tag": "SET CLUSTER SETTING", "User": "root", "Value": "'some string'"}
519517

pkg/sql/logictest/testdata/logic_test/system

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,6 @@ ORDER BY name
314314
----
315315
cluster.secret
316316
diagnostics.reporting.enabled
317-
feature.vector_index.enabled
318317
sql.crdb_internal.table_row_statistics.as_of_time
319318
sql.vecindex.deterministic_fixups.enabled
320319
version
@@ -332,7 +331,6 @@ ORDER BY name
332331
----
333332
cluster.secret
334333
diagnostics.reporting.enabled
335-
feature.vector_index.enabled
336334
sql.crdb_internal.table_row_statistics.as_of_time
337335
sql.vecindex.deterministic_fixups.enabled
338336
version
@@ -355,7 +353,6 @@ AND name NOT IN ('version', 'cluster.secret', 'kv.range_merge.queue_enabled')
355353
ORDER BY name
356354
----
357355
diagnostics.reporting.enabled true
358-
feature.vector_index.enabled true
359356
somesetting somevalue
360357
sql.crdb_internal.table_row_statistics.as_of_time -1µs
361358
sql.vecindex.deterministic_fixups.enabled true
@@ -373,7 +370,6 @@ AND name NOT IN ('version', 'cluster.secret')
373370
ORDER BY name
374371
----
375372
diagnostics.reporting.enabled true
376-
feature.vector_index.enabled true
377373
somesetting somevalue
378374
sql.crdb_internal.table_row_statistics.as_of_time -1µs
379375
sql.vecindex.deterministic_fixups.enabled true

0 commit comments

Comments
 (0)