Browse Source

Fix for TCP connections not sending full content

Eventlet previously broke the standard API for sockets
and made socket.send() work in the same manor as socket.sendall()

c315ee86da
reverted to the standard behaviour.

This was released as part of 0.18.0.

The bug manifests itself when large (multi TCP message) AXFRs are
performed over long distances.

(I replicated it when the messages grew to 3,
over USWest -> EU transfer)

see http://graham.hayes.ie/posts/minidns-tcp-and-the-internet/
for details on testing.

This change can cause packets to be dropped intermitently -
but retry will allow this to be overcome.

Change-Id: Ia0c15d843fb2092cc693b37dc701492396c647d0
Closes-Bug: #1552864
(cherry picked from commit f2c06477af)
(cherry picked from commit 6c49166b06)
Graham Hayes 3 years ago
parent
commit
a4b4c6dfb8
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      designate/service.py

+ 1
- 1
designate/service.py View File

@@ -364,7 +364,7 @@ class DNSService(object):
364 364
                         # Handle TCP Responses
365 365
                         msg_length = len(response)
366 366
                         tcp_response = struct.pack("!H", msg_length) + response
367
-                        client.send(tcp_response)
367
+                        client.sendall(tcp_response)
368 368
                     else:
369 369
                         # Handle UDP Responses
370 370
                         self._dns_sock_udp.sendto(response, addr)

Loading…
Cancel
Save