Created
April 27, 2018 09:19
-
-
Save benasse/48b0a1665a8346242df596a5eda8b678 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
import sys, socket, time | |
host = "outscale.com" | |
service = "http" | |
family = socket.AF_UNSPEC | |
socktype = socket.SOCK_STREAM | |
protocol = socket.SOL_TCP | |
flags = 0 | |
while True: | |
debut = time.time() | |
result = socket.getaddrinfo(host, service, family, socktype, protocol, flags) | |
fin = time.time() | |
print(fin - debut) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment