perlin-network / noise

A decentralized P2P networking stack written in Go.
https://godoc.org/github.com/perlin-network/noise
MIT License
1.78k stars 213 forks source link

client, conn: remove idle timeout goroutine and use net.Conn read/write deadlines instead #270

Closed iwasaki-kenta closed 4 years ago

iwasaki-kenta commented 4 years ago

This removes the need for there being one extraneous goroutine per connection and removes the need for keeping track of an idle timeout timer per *noise.Client.

codecov[bot] commented 4 years ago

Codecov Report

Merging #270 into master will decrease coverage by 0.56%. The diff coverage is 70%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #270      +/-   ##
==========================================
- Coverage   69.59%   69.02%   -0.57%     
==========================================
  Files          19       19              
  Lines        1197     1172      -25     
==========================================
- Hits          833      809      -24     
  Misses        266      266              
+ Partials       98       97       -1
Impacted Files Coverage Δ
client.go 62.84% <50%> (-3%) :arrow_down:
conn.go 78.87% <75%> (-1.13%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 64da665...48a6488. Read the comment docs.