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

cofacts / rumors-line-bot / 36387343663
91%
master: 91%

Build:
Build:
LAST BUILD BRANCH: fix/pm2-wait-ready
DEFAULT BRANCH: master
Ran 28 Sep 2026 06:40AM UTC
Jobs 1
Files 59
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

28 Sep 2026 06:36AM UTC coverage: 90.688%. Remained the same
36387343663

Pull #417

github

MrOrz
fix: gracefully stop accepting connections on SIGINT before PM2 kills the worker

The hourly `pm2 reload all` cron (devops' cofacts-ops, "Chatbot group 重啟")
rolling-restarts this app's cluster workers. The old SIGINT handler called
process.exit() immediately after redis.quit(), giving the HTTP server no
chance to stop accepting new connections first — any keep-alive connection
the reverse proxy held open to that specific worker (including idle ones)
was severed the instant the process exited. Combined with PM2's default 1.6s
kill_timeout, there was barely any window for this to happen safely.

Add server.close() to the SIGINT handler and raise kill_timeout to 15s so
the old worker has real time to stop taking new connections before PM2
SIGKILLs it. This is a distinct trigger for the same LINE webhook
`request_timeout` symptom as the keepAliveTimeout fix — not addressed by it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Pull Request #417: fix: gracefully stop accepting connections on SIGINT before PM2 kills the worker

544 of 645 branches covered (84.34%)

Branch coverage included in aggregate %.

1131 of 1202 relevant lines covered (94.09%)

12.39 hits per line

Jobs
ID Job ID Ran Files Coverage
1 36387343663.1 28 Sep 2026 06:40AM UTC 59
90.69
GitHub Action Run
Source Files on build 36387343663
  • Tree
  • List 59
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Pull Request #417
  • PR Base - master (#36220297238)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc