This file contains 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
can you write me some python async code that reads urls off of a kafka topic called incoming_urls and then uses headless selenium to download the webpages html , parses that links from it, and send the following json to a second kafka topic called outgoing html: | |
json{ | |
html: $pagebody, | |
links: [] $urls_parsed_from_the_html | |
headers: $html_headers, | |
machineip: $private_ip, | |
log: $/var/logs/crawler.log, | |
errors: $errorsEncountered | |
} |