AWS Postgres 设置 pg_trgm.word_similarity_threshold

问题描述 投票:0回答:1

我正在尝试在 RDS postgres (13) 实例上设置 pg_trgm.word_similarity_threshold GUC 参数。

我尝试使用部署后 SQL 脚本进行设置:

SET pg_trgm.word_similarity_threshold = 0.5;
SELECT pg_reload_conf();

但这会导致错误:

Npgsql.PostgresException (0x80004005): 42501: permission denied for function pg_reload_conf

我还尝试通过 terraform 设置它,将其传递到 parameters 列表中:

parameters = [
  {
    name         = "shared_preload_libraries"
    value        = "pg_cron,pg_stat_statements,pg_trgm"
    apply_method = "pending-reboot"
  },
  {
    name         = "pg_trgm.word_similarity_threshold"
    value        = "0.5"
    apply_method = "immediate" # I don't know if this is a static or dynamic variable
  }
]

这会导致错误:

Error modifying DB Parameter Group: InvalidParameterValue: Could not find parameter with name: pg_trgm.word_similarity_threshold

尽管 pg_trgm 是受支持的扩展,但该参数在 postgres 参数组中似乎不可用。有什么方法可以在我的 AWS Postgres RDS 中设置此参数吗?


postgresql amazon-web-services terraform amazon-rds pg-trgm
1个回答
0
投票

这似乎不可能。两年前就承诺过会实施,但目前还没有采取任何行动。

查看官方答案:https://repost.aws/questions/QUhf2ksaV2SA-MWaw04M4U_Q/changing-pg-trgm-similarity-threshold-in-rds

© www.soinside.com 2019 - 2024. All rights reserved.