8000 Go runtime Signal 23 (SIGURG) before child process is running causes preflight to silently exit · Issue #16 · monzo/envoy-preflight · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Go runtime Signal 23 (SIGURG) before child process is running causes preflight to silently exit #16
Open
@dnwe

Description

@dnwe

The Go runtime scheduling uses signal 23 (SIGURG) since Go 1.14 (see 24543-non-cooperative-preemption.md). Because the Go runtime does not know if the process expects external SIGURG signals, the signal is not filtered out from signal.Notify, but always reported to the process (see golang/go#37942 for discussion). Preflight should filter this signal out itself before forwarding and when the child process isn't up yet it should also not exit when it is received.

envoy-preflight/main.go

Lines 46 to 53 in eb1500e

signal.Notify(stop)
for sig := range stop {
if proc != nil {
proc.Signal(sig)
} else {
// Signal received before the process even started. Let's just exit.
os.Exit(1)
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0