Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow more active redis connections #407

Merged
merged 1 commit into from
Jan 19, 2022
Merged

Allow more active redis connections #407

merged 1 commit into from
Jan 19, 2022

Conversation

rowanseymour
Copy link
Member

No description provided.

MaxIdle: 4, // only keep up to this many idle
IdleTimeout: 240 * time.Second, // how long to wait before reaping a connection
Dial: func() (redis.Conn, error) {
conn, err := redis.Dial("tcp", fmt.Sprintf("%s", redisURL.Host))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

linter complains that it's already a string

@codecov
Copy link

codecov bot commented Jan 19, 2022

Codecov Report

Merging #407 (8b01318) into main (fd95b68) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #407   +/-   ##
=======================================
  Coverage   71.99%   71.99%           
=======================================
  Files          95       95           
  Lines        8294     8294           
=======================================
  Hits         5971     5971           
  Misses       1731     1731           
  Partials      592      592           
Impacted Files Coverage Δ
backends/rapidpro/backend.go 67.19% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fd95b68...8b01318. Read the comment docs.

@@ -592,11 +592,11 @@ func (b *backend) Start() error {
// create our pool
redisPool := &redis.Pool{
Wait: true, // makes callers wait for a connection
MaxActive: 8, // only open this many concurrent connections at once
MaxActive: 36, // only open this many concurrent connections at once
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

matches what we have in mailroom

@rowanseymour rowanseymour merged commit 347d806 into main Jan 19, 2022
@rowanseymour rowanseymour deleted the more_redis_conns branch January 19, 2022 14:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant