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

mongodb-js / devtools-shared / 28511749931 / 21 – mongodb-runner
79%
main: 79%

Build:
Build:
LAST BUILD BRANCH: MONGOSH-3244-idx-variable
DEFAULT BRANCH: main
Ran 01 Jul 2026 10:57AM UTC
Files 11
Run time 1s
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

01 Jul 2026 10:40AM UTC coverage: 80.948%. First build
mongodb-runner – 28511749931.21

Pull #809

github

ivandevp
fix(devtools-proxy-support): serialize SSH reinit and cap consecutive failures HELP-96049

When the SSH tunnel breaks during hibernate, concurrent _connect() callers all
hit initialize(reinitializeClient=true) simultaneously. Because that path
bypasses the connectingPromise deduplication guard, every caller raced through
the reinit — each calling sshClient.end() + createSshClient() + connect() —
producing N new server-side SSH sessions per MongoDB driver retry cycle. With
the driver retrying every ~10 s indefinitely, sessions accumulated without
bound (300+ observed in the field, exhausting the bastion's RAM).

Two changes:

1. Serialize concurrent reinit attempts via reinitializingPromise. The first
   caller to reach initialize(true) owns the reinit; subsequent concurrent
   callers await that same promise and then fall through to initialize(false)
   to use the freshly-connected client. Only one new SSH session is opened per
   reinit cycle regardless of how many _connect() callers are in flight.

2. Cap consecutive reinit failures. A new consecutiveReinitFailures counter
   increments each time _doReinit() fails and resets to zero on success. After
   MAX_CONSECUTIVE_REINIT_FAILURES (3) consecutive failures the agent sets
   closed=true, causing all subsequent initialize() calls to throw
   'Disconnected.' immediately. This surfaces a clean error to the MongoDB
   driver rather than looping indefinitely and leaking sessions.
Pull Request #809: fix(devtools-proxy-support): serialize SSH reinit and cap consecutive failures HELP-96049

299 of 389 branches covered (76.86%)

Branch coverage included in aggregate %.

623 of 750 relevant lines covered (83.07%)

671.6 hits per line

Source Files on job mongodb-runner - 28511749931.21
  • Tree
  • List 11
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 28511749931
  • 8e9ee347 on github
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

© 2026 Coveralls, Inc