{"action":"opened","issue":{"url":"https://api.github.com/repos/golang/go/issues/10685","labels_url":"https://api.github.com/repos/golang/go/issues/10685/labels{/name}","comments_url":"https://api.github.com/repos/golang/go/issues/10685/comments","events_url":"https://api.github.com/repos/golang/go/issues/10685/events","html_url":"https://github.com/golang/go/issues/10685","id":73125703,"number":10685,"title":"tls handshake EOF when using a goroutine in http/websockets","user":{"login":"bbangert","id":100193,"avatar_url":"https://avatars.githubusercontent.com/u/100193?v=3","gravatar_id":"","url":"https://api.github.com/users/bbangert","html_url":"https://github.com/bbangert","followers_url":"https://api.github.com/users/bbangert/followers","following_url":"https://api.github.com/users/bbangert/following{/other_user}","gists_url":"https://api.github.com/users/bbangert/gists{/gist_id}","starred_url":"https://api.github.com/users/bbangert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbangert/subscriptions","organizations_url":"https://api.github.com/users/bbangert/orgs","repos_url":"https://api.github.com/users/bbangert/repos","events_url":"https://api.github.com/users/bbangert/events{/privacy}","received_events_url":"https://api.github.com/users/bbangert/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-04T20:53:58Z","updated_at":"2015-05-04T20:53:58Z","closed_at":null,"body":"When using SSL and websockets (using either gorilla or golang.org's websocket lib), moderate connection load will result in clients not connecting properly, and this message:\r\n\r\n```\r\n2015/05/04 13:31:58 http: TLS handshake error from 127.0.0.1:5253: EOF\r\n2015/05/04 13:31:58 http: TLS handshake error from 127.0.0.1:5254: EOF\r\n2015/05/04 13:31:58 http: TLS handshake error from 127.0.0.1:5255: EOF\r\n2015/05/04 13:31:58 http: TLS handshake error from 127.0.0.1:5256: EOF\r\n2015/05/04 13:31:58 http: TLS handshake error from 127.0.0.1:5257: EOF\r\n```\r\n\r\nThis doesn't happen in my basic example (located here:  https://github.com/bbangert/ssl-ram-testing/blob/master/Go/golang.org/main.go) when it uses io.Copy to implement the echo server, but when it merely uses another goroutine to write the echo'd data back then the TLS handshake errors pop up.\r\n\r\nI observed this using the latest Go 1.4.2, we have observed it in prior versions of Go in production, but this is the first time I have a minimal example of it (for testing SSL RAM overhead per connection, which is very very high in Golang, but that's a separate issue....)."}}