• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

bolshakov / stoplight / 14464967390
100%

Build:
DEFAULT BRANCH: master
Ran 15 Apr 2025 08:34AM UTC
Jobs 3
Files 26
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

15 Apr 2025 08:34AM UTC coverage: 100.0%. Remained the same
14464967390

push

github

web-flow
Add support for Redis connection pooling (#298)

Adds support for using connection pools with the Redis data store. This allows Stoplight
to efficiently manage Redis connections in multi-threaded environments, preventing
connection exhaustion in high-traffic applications.

* Added connection_pool gem to development dependencies
* Modified the Redis data store to accept either a direct Redis client or a ConnectionPool instance
* Used `.then` method to safely access the Redis client from either source
* Updated specs to test both direct Redis client and ConnectionPool scenarios
* Added documentation for connection pooling usage

The `Stoplight::DataStore::Redis` class now accepts either a `Redis` client or a `ConnectionPool` of
Redis clients in its constructor. It then uses the `.then` method to handle both cases uniformly:

```ruby
@redis.hset(states_key, config.name, state)

@redis.then { _1.hset(states_key, config.name, state) }
```

This change is backward compatible and should not affect existing code. Users who want to take advantage of connection pooling will need to add the +connection_pool+ gem to their dependencies and update their configuration as shown in the documentation.

30 of 30 new or added lines in 1 file covered. (100.0%)

519 of 519 relevant lines covered (100.0%)

272.05 hits per line

Jobs
ID Job ID Ran Files Coverage
1 ruby-3.2 - 14464967390.1 15 Apr 2025 08:34AM UTC 26
100.0
GitHub Action Run
2 ruby-3.4 - 14464967390.2 15 Apr 2025 08:35AM UTC 26
100.0
GitHub Action Run
3 ruby-3.3 - 14464967390.3 15 Apr 2025 08:34AM UTC 26
100.0
GitHub Action Run
Source Files on build 14464967390
  • Tree
  • List 26
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 4ee87694 on github
  • Prev Build on master (#14442780381)
  • Next Build on master (#14466914142)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc