Skip to content

Commit

Permalink
Merge pull request #25 from hellysmile/shutdown_timeout
Browse files Browse the repository at this point in the history
shutdown_timeout=2.0
  • Loading branch information
claws committed May 24, 2018
2 parents 9905441 + f361b88 commit 668e5d3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/aioprometheus/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,9 @@ async def start(

self._https = ssl is not None
try:
self._site = aiohttp.web.TCPSite(self._runner, addr, port, ssl_context=ssl)
self._site = aiohttp.web.TCPSite(
self._runner, addr, port, ssl_context=ssl, shutdown_timeout=2.0
)
await self._site.start()
except Exception:
logger.exception("error creating metrics server")
Expand Down

0 comments on commit 668e5d3

Please sign in to comment.