[Win32 Signals] Add term and ctrl-c signal handlers#13954
[Win32 Signals] Add term and ctrl-c signal handlers#13954ggreenway merged 35 commits intoenvoyproxy:masterfrom
Conversation
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
|
@envoyproxy/windows-dev |
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
wrowe
left a comment
There was a problem hiding this comment.
This approach is otherwise looking good to me. In the shutdown/logoff cases, I've found that returning immediately from the CtrlHandler causes the typical "now attempt to kill" reaction immediately from the OS, so a delay is usually helpful.
antoniovicente
left a comment
There was a problem hiding this comment.
Thanks for the continued help to improve cross platform support.
|
I am adding a /wait tag as I am working more with the automated test. @sunjayBhatia was right and the ctrl+break is caught from the test regardless of the signal handling. I am working on adding ctrl + c signals in the tests but it is a bit tricky. |
|
/wait |
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
|
@sunjayBhatia thanks for the suggestion! It worked. |
|
/retest |
|
Retrying Azure Pipelines: |
|
@wrowe and @antoniovicente PTAL when you get some time |
antoniovicente
left a comment
There was a problem hiding this comment.
Change looks pretty much ready to merge. Just a few minor questions. Sorry for the delays in review, this one really went to the back burner.
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
|
/retest |
|
Retrying Azure Pipelines: |
|
@envoyproxy/senior-maintainers can I also get a review from one of you! |
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
|
@ggreenway I addressed most of the comments and I am looking for some further clarification is some comments that I have left open. Thanks for the code review! |
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
Signed-off-by: Sotiris Nanopoulos <sonanopo@microsoft.com>
* master: (41 commits) event: Remove a source of non-determinism by always running deferred deletion before post callbacks (envoyproxy#14293) Fix TSAN bug in integration test (envoyproxy#14327) tracing: Add hostname to Zipkin config. (envoyproxy#14186) (envoyproxy#14187) [conn_pool] fix use after free in H/1 connection pool (envoyproxy#14220) lua: update deprecated lua_open to luaL_newstate (envoyproxy#14297) extension: use bool_flag to control extension link (envoyproxy#14240) stats: Factor out creation of cluster-stats StatNames from creation of the stats, to save CPU during xDS updates (envoyproxy#14028) test: add scaled timer integration test (envoyproxy#14290) [Win32 Signals] Add term and ctrl-c signal handlers (envoyproxy#13954) config: v2 transport API fatal-by-default. (envoyproxy#14223) matcher: fix UB bug caused by dereferencing a bad optional (envoyproxy#14271) test: putting fake upstream config in a struct (envoyproxy#14266) wasm: use Bazel rules from Proxy-Wasm Rust SDK. (envoyproxy#14292) docs: fix typo (envoyproxy#14237) dependencies: allowlist CVE-2018-21270 to prevent false positives. (envoyproxy#14294) typo in redis doc (envoyproxy#14248) access_loggers: removed redundant dep (envoyproxy#14274) fix http2 flaky test (envoyproxy#14261) test: disable flaky xds_integration_test. (envoyproxy#14287) http: add functionality to configure kill header in KillRequest proto (envoyproxy#14288) ... Signed-off-by: Michael Puncel <mpuncel@squareup.com>
Signed-off-by: Sotiris Nanopoulos sonanopo@microsoft.com
Part 1 of #13188. Adds support for
ctrl+candctrl+breakfor Envoy on Windows.The implementation for this following:
platform_implwe register aCtrlHandlerwhich runs on a separate thread.signal_implwe register a read event reader.Thread (1) and (2) communicate via a socket pair and the event is handled on Windows the same way as it is handled on POSIX
Risk Level: Low (Windows Only)
Testing: Manual testing + integration tests
Docs Changes: N/A
Release Notes: N/A