This commit is contained in:
pigwin
2025-12-23 16:44:24 +00:00
parent 9b433cdd57
commit 00e6667bc0
3 changed files with 4 additions and 4 deletions

View File

@@ -10,7 +10,7 @@
"valkey": {
"host": "127.0.0.1",
"port": "6379",
"max_conns": 110,
"max_conns": 100,
"timeout_ms": 2000,
"password": "the_valkey_password"
},

View File

@@ -28,8 +28,8 @@ func ConnectToPostgreSQL() (*sql.DB, error) {
}
// Set connection pool settings for high concurrency
db.SetMaxOpenConns(100) // Maximum number of open connections to the database
db.SetMaxIdleConns(50) // Maximum number of connections in the idle connection pool
db.SetMaxOpenConns(50) // Maximum number of open connections to the database
db.SetMaxIdleConns(25) // Maximum number of connections in the idle connection pool
db.SetConnMaxLifetime(1 * time.Hour) // Maximum amount of time a connection may be reused
db.SetConnMaxIdleTime(5 * time.Minute) // Maximum amount of time a connection may be idle

View File

@@ -9,7 +9,7 @@ import (
)
func main() {
log.Println("ti1 testing v1.X1")
log.Println("ti1 testing v1.0.0")
log.Println("Starting...")
// Setup the database