FEATURE: allow users to specify if prepared statements are allowed

(they need to be disabled for pgpool based setups)
This commit is contained in:
Sam 2015-02-18 11:16:53 +11:00
parent fe31d45131
commit fff55e0ee3
2 changed files with 6 additions and 0 deletions

View File

@ -26,6 +26,8 @@ class GlobalSetting
hash["host_names"] = [ hostname ] hash["host_names"] = [ hostname ]
hash["database"] = db_name hash["database"] = db_name
hash["prepared_statements"] = !!self.db_prepared_statements
{"production" => hash} {"production" => hash}
end end

View File

@ -39,6 +39,10 @@ db_username = discourse
# password used to access the db # password used to access the db
db_password = db_password =
# allow usage of prepared statements, must be disabled for
# pgpool transaction pooling
db_prepared_statements = true
# hostname running the forum # hostname running the forum
hostname = "www.example.com" hostname = "www.example.com"