The maximum time, in seconds per day, that the index advisor spends
running automated analyses of its tracked queries.
google_db_advisor.auto_advisor_schedule
Type
String
Default
'EVERY 24 HOURS'
Restart required
No
Defines the frequency of the index advisor's automated
analysis. The value is a single-quoted string of the format
'EVERY NUNITS', where
N is an integer, and UNITS is either
HOURS or DAYS.
google_db_advisor.enable_auto_advisor
Type
Boolean
Default
on
Restart required
No
If on, then AlloyDB runs the
index advisor's analysis on an automated schedule, with a
frequency set by the separate
google_db_advisor.auto_advisor_schedule flag.
google_db_advisor.enabled
Type
Boolean
Default
on
Restart required
Yes
Controls whether the AlloyDB index advisor is
enabled.
google_db_advisor.max_index_width
Type
Integer
Default
2
Restart required
No
The maximum number of columns that a recommended index can
contain.
google_db_advisor.max_num_indexable_columns
Type
Integer
Default
1000
Restart required
No
The maximum number of indexable columns that index advisor
tracks.
google_db_advisor.max_statement_length
Type
Integer
Default
102400
Restart required
No
The maximum length, in bytes, of queries that the index
advisor tracks.
google_db_advisor.max_storage_size_in_mb
Type
Integer
Default
0
Restart required
No
The maximum total size, in megabytes, of the indexes
that the index advisor recommends.
If set to
0, then AlloyDB uses the current
database size as the upper limit on the total size of recommended
indexes.
google_db_advisor.recommend_indexes_on_partitions
Type
Boolean
Default
off
Restart required
No
Controls whether to enable recommending indexes on
individual table partitions.
The maximum time, in seconds, that the index advisor spends
running an analysis of its tracked queries.
google_db_advisor.top_k_slowest_statements
Type
Integer
Default
100
Restart required
No
The index advisor bases its recommendations on the
slowest-executing statements out of all the queries it tracks.
The value set by this flag defines the size of this
set.
If set to 2147483647 (the maximum allowed
value), then AlloyDB recommends indexes based
on all captured statements, instead of on a limited number of
statements.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-05 UTC."],[[["This page details the database flags used by AlloyDB for PostgreSQL to manage its index advisor extension."],["The `google_db_advisor.enabled` flag controls whether the index advisor is active, and this requires a restart to take effect."],["The `google_db_advisor.auto_advisor_schedule` and `google_db_advisor.enable_auto_advisor` flags are used to determine the frequency and enable automatic analysis."],["Flags such as `google_db_advisor.max_index_width`, `google_db_advisor.max_storage_size_in_mb` and others, allow customization of the index advisor's behavior, such as limiting index characteristics, storage used and tracked statement length."],["The `google_db_advisor.top_k_slowest_statements` flag allows to determine how many of the slowest statements are used for the index recommendations, while setting it to `2147483647` will use all tracked statements."]]],[]]