netdns2 icon indicating copy to clipboard operation
netdns2 copied to clipboard

Feature Request: multiple queries in parallel to speed up things

Open deepika-maj opened this issue 5 years ago • 2 comments

it would be really nice if this library supports doing multiple queries in parallel so that it will reduce the processing time.

at the moment I am doing it like below:

$resolver = new \Net_DNS2_Resolver([
    'nameservers' => $nameServers,
    'ns_random' => true
]);

$types = ['A', 'NS', 'TXT', 'MX'];
foreach ($types as $type) {
    $response = $resolver->query($hostName, $type);
    // response processing
}

deepika-maj avatar Oct 05 '19 10:10 deepika-maj

Did you try $response = $resolver->query($hostName, '*') ?

andrii-pukhalevych avatar Aug 04 '22 10:08 andrii-pukhalevych

maybe https://github.com/spatie/async ?

Pascal76 avatar Feb 14 '24 10:02 Pascal76