Send bulk IPWhois requests
I created a python script to use the library ipwhois and send API requests to get information about some IP addresses. I am using the function lookup_rdap to achieve this. My problem is that each request takes a lot of time and I want to search for thousands of IP addresses.
I read the documentation and cannot spot any function that can be used to send multiple concurrent requests for multiple IP addresses.
A for loop is used to run through all execl rows to read every single IP address
for i in range(1,sheet1.max_row + 1): obj = IPWhois(sheet1["A" + str(i)].value) results = obj.lookup_rdap(depth=1)
I would like to ask you if anyone know about such a function? Or if you can think any clever way to send multiple such requests instead of waiting for each of them to be executed, as python is executed from top to bottom. Is there any way to tell Python, while you are waiting for the first request, proceed with the second one and then the third one, etc.?
Thank you in advance, Georgios