iijlab / direct-hs

Client library for https://direct4b.com in Haskell
8 stars 1 forks source link

Feature request: graceful shutdown #15

Closed igrep closed 6 years ago

igrep commented 6 years ago

According to developers of LisB and a bot provider I talked with, we should add some feature to resume a channel (conversation with a user) after bot restarts during the conversation. They said that with bots with a huge number of users, someone often accidentally stops their conversations due to some reasons. Without resume feature, the state of conversations gets lost when the bot shuts down or crash.

kazu-yamamoto commented 6 years ago

Resume is important for Direct JS since Hubot is rebooted repeatedly. However, Direct HS is not rebooted repeatedly and will be rebooted at maintenance time For Direct HS, it is important to prepare graceful shutdown feature. So, let's prepare an API to signal all existing worker threads to send a maintenance message to their user.