Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2021-11-17 00:34:33 +0300
committerStan Hu <stanhu@gmail.com>2021-11-17 00:36:13 +0300
commita783ac33976d1efa428eecf1b1cec4a16dd5742e (patch)
tree20fc9f6727ef6480f46bb9a40a5b7578aa0efdf7
parent284a2395b24fcbf1614f486a190379bf42eac6a6 (diff)
demo: Activate PostgreSQL slow logs
This commit will cause PostgreSQL to log any database statements taking longer than 500 ms. This is useful to flag any slow queries running in Praefect.
-rw-r--r--_support/terraform/terraform/main.tf5
1 files changed, 5 insertions, 0 deletions
diff --git a/_support/terraform/terraform/main.tf b/_support/terraform/terraform/main.tf
index 92c38127b..283214279 100644
--- a/_support/terraform/terraform/main.tf
+++ b/_support/terraform/terraform/main.tf
@@ -47,6 +47,11 @@ resource "google_sql_database_instance" "praefect_sql" {
settings {
tier = "db-f1-micro"
+ database_flags {
+ name = "log_min_duration_statement"
+ value = "500"
+ }
+
ip_configuration{
ipv4_enabled = true