MCPcopy
hub / github.com/segmentio/kafka-go / setDeadline

Method setDeadline

conn.go:1518–1531  ·  view source on GitHub ↗
(t time.Time)

Source from the content-addressed store, hash-verified

1516}
1517
1518func (d *connDeadline) setDeadline(t time.Time) {
1519 d.mutex.Lock()
1520 d.value = t
1521
1522 if d.rconn != nil {
1523 d.rconn.SetReadDeadline(t)
1524 }
1525
1526 if d.wconn != nil {
1527 d.wconn.SetWriteDeadline(t)
1528 }
1529
1530 d.mutex.Unlock()
1531}
1532
1533func (d *connDeadline) setConnReadDeadline(conn net.Conn) time.Time {
1534 d.mutex.Lock()

Callers 3

SetDeadlineMethod · 0.80
SetReadDeadlineMethod · 0.80
SetWriteDeadlineMethod · 0.80

Calls 2

SetReadDeadlineMethod · 0.45
SetWriteDeadlineMethod · 0.45

Tested by

no test coverage detected