Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

improve HTTP server shutdown

Open
#206 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
38/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
swift

Research direction

Start with the shutdown flow in Vapor/HTTPServer.swift, especially the log locations around lines 368-374, and trace how Boka.swift and Vapor/Application.swift trigger it. Check the available Vapor API for closing the WebSocket during shutdown; done means the HTTP server stops without the ten-second timeout error.

Written by the indexing model from the issue text.

Description

2024-10-29T17:35:01+1300 [ cli ] [ NOTICE ] Shutting down... (Boka/Boka.swift:184)
2024-10-29T17:35:01+1300 [ codes.vapor.application ] [ DEBUG ] Application shutting down (Vapor/Application.swift:264)
2024-10-29T17:35:01+1300 [ codes.vapor.application ] [ TRACE ] Shutting down providers (Vapor/Application.swift:266)
2024-10-29T17:35:01+1300 [ codes.vapor.application ] [ TRACE ] Clearing Application storage (Vapor/Application.swift:270)
2024-10-29T17:35:01+1300 [ codes.vapor.application ] [ DEBUG ] Requesting HTTP server shutdown (Vapor/HTTPServer.swift:368)
2024-10-29T17:35:11+1300 [ codes.vapor.application ] [ ERROR ] Could not stop HTTP server: Abort.500: Server stop took too long. (Vapor/HTTPServer.swift:372)
2024-10-29T17:35:11+1300 [ codes.vapor.application ] [ DEBUG ] HTTP server shutting down (Vapor/HTTPServer.swift:374)
2024-10-29T17:35:11+1300 [ codes.vapor.application ] [ TRACE ] Running on shared EventLoopGroup. Not shutting down EventLoopGroup. (Vapor/Application.swift:276)
2024-10-29T17:35:11+1300 [ codes.vapor.application ] [ TRACE ] Application shutdown complete (Vapor/Application.swift:287)
2024-10-29T17:35:11+1300 [ codes.vapor.application ] [ TRACE ] Application deinitialized, goodbye! (Vapor/Application.swift:321)

it shouldn't shutdown by timeout. need to use some Vapor API to close ws

Dominant language
Swift
Stars
6
Forks
0
Avg merge
1d 4h
Merged PRs (30d)
3

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from open-web3-stack/boka

All issues in open-web3-stack/boka

Similar issues

More Swift issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.