feat: support shutdown_callback argument in XXXAsyncServer#311
feat: support shutdown_callback argument in XXXAsyncServer#311vigith merged 3 commits intonumaproj:mainfrom
Conversation
Signed-off-by: Kazuki Yamamoto <yamamoto.kazuki.24@gmail.com>
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #311 +/- ##
==========================================
+ Coverage 94.00% 94.06% +0.05%
==========================================
Files 66 66
Lines 3053 3083 +30
Branches 156 156
==========================================
+ Hits 2870 2900 +30
Misses 136 136
Partials 47 47 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
vigith
left a comment
There was a problem hiding this comment.
self.shutdwon_callback = shutdown_callbackplease fix the typo here and at the usage sites too?
| so that all the async coroutines can be started from a single context | ||
| """ | ||
| aiorun.run(self.aexec(), use_uvloop=True) | ||
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdwon_callback) |
There was a problem hiding this comment.
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdwon_callback) | |
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdown_callback) |
typo
| to the aexec so that all the async coroutines can be started from a single context | ||
| """ | ||
| aiorun.run(self.aexec(), use_uvloop=True) | ||
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdwon_callback) |
There was a problem hiding this comment.
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdwon_callback) | |
| aiorun.run(self.aexec(), use_uvloop=True, shutdown_callback=self.shutdown_callback) |
typo
| self.max_threads = min(max_threads, MAX_NUM_THREADS) | ||
| self.max_message_size = max_message_size | ||
| self.server_info_file = server_info_file | ||
| self.shutdwon_callback = shutdown_callback |
There was a problem hiding this comment.
| self.shutdwon_callback = shutdown_callback | |
| self.shutdown_callback = shutdown_callback |
| self.max_threads = min(max_threads, MAX_NUM_THREADS) | ||
| self.max_message_size = max_message_size | ||
| self.server_info_file = server_info_file | ||
| self.shutdwon_callback = shutdown_callback |
There was a problem hiding this comment.
| self.shutdwon_callback = shutdown_callback | |
| self.shutdown_callback = shutdown_callback |
Signed-off-by: Kazuki Yamamoto <yamamoto.kazuki.24@gmail.com>
|
Can you please make the same change in the remaining files as well to make the API consistent?
Also, please update the documentation comment for this parameter (within the class or under |
- Also, update the documentation comment for this parameter Signed-off-by: Kazuki Yamamoto <yamamoto.kazuki.24@gmail.com>
As discussed in #310, I updated the following code in accordance with the proposed solution.