mirror of
https://github.com/maelgangloff/domain-watchdog.git
synced 2025-12-17 17:55:42 +00:00
feat: add low priority RDAP message queue
This commit is contained in:
parent
8556308290
commit
d2a5059a65
@ -9,7 +9,7 @@ framework:
|
|||||||
retry_strategy:
|
retry_strategy:
|
||||||
max_retries: 3
|
max_retries: 3
|
||||||
multiplier: 2
|
multiplier: 2
|
||||||
rdap_async:
|
rdap_high:
|
||||||
dsn: '%env(MESSENGER_RDAP_ASYNC_TRANSPORT_DSN)%'
|
dsn: '%env(MESSENGER_RDAP_ASYNC_TRANSPORT_DSN)%'
|
||||||
options:
|
options:
|
||||||
consumer: '%env(MESSENGER_CONSUMER_NAME)%'
|
consumer: '%env(MESSENGER_CONSUMER_NAME)%'
|
||||||
@ -18,6 +18,15 @@ framework:
|
|||||||
multiplier: 2
|
multiplier: 2
|
||||||
max_delay: 86400000
|
max_delay: 86400000
|
||||||
|
|
||||||
|
rdap_low:
|
||||||
|
dsn: '%env(MESSENGER_RDAP_ASYNC_TRANSPORT_DSN)%'
|
||||||
|
options:
|
||||||
|
consumer: '%env(MESSENGER_CONSUMER_NAME)%'
|
||||||
|
retry_strategy:
|
||||||
|
delay: 2000
|
||||||
|
multiplier: 2
|
||||||
|
max_delay: 86400000
|
||||||
|
|
||||||
failed: 'doctrine://default?queue_name=failed'
|
failed: 'doctrine://default?queue_name=failed'
|
||||||
# sync: 'sync://'
|
# sync: 'sync://'
|
||||||
|
|
||||||
@ -37,4 +46,4 @@ framework:
|
|||||||
App\Message\ProcessWatchlist: async
|
App\Message\ProcessWatchlist: async
|
||||||
App\Message\UpdateRdapServers: async
|
App\Message\UpdateRdapServers: async
|
||||||
App\Message\ValidateConnectorCredentials: async
|
App\Message\ValidateConnectorCredentials: async
|
||||||
App\Message\UpdateDomain: rdap_async
|
App\Message\UpdateDomain: rdap_high
|
||||||
|
|||||||
@ -11,6 +11,7 @@ use Symfony\Component\Console\Output\OutputInterface;
|
|||||||
use Symfony\Component\Console\Style\SymfonyStyle;
|
use Symfony\Component\Console\Style\SymfonyStyle;
|
||||||
use Symfony\Component\Messenger\Exception\ExceptionInterface;
|
use Symfony\Component\Messenger\Exception\ExceptionInterface;
|
||||||
use Symfony\Component\Messenger\MessageBusInterface;
|
use Symfony\Component\Messenger\MessageBusInterface;
|
||||||
|
use Symfony\Component\Messenger\Stamp\TransportNamesStamp;
|
||||||
|
|
||||||
#[AsCommand(
|
#[AsCommand(
|
||||||
name: 'app:batch-register-domains',
|
name: 'app:batch-register-domains',
|
||||||
@ -54,7 +55,9 @@ class BatchRegisterDomainCommand extends Command
|
|||||||
$io->title('Registering domains');
|
$io->title('Registering domains');
|
||||||
/** @var string $ldhName */
|
/** @var string $ldhName */
|
||||||
foreach ($domains as $ldhName) {
|
foreach ($domains as $ldhName) {
|
||||||
$this->messageBus->dispatch(new UpdateDomain($ldhName, null));
|
$this->messageBus->dispatch(new UpdateDomain($ldhName, null), [
|
||||||
|
new TransportNamesStamp('rdap_low'),
|
||||||
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
$io->success(sprintf('Imported %d domain names.', count($domains)));
|
$io->success(sprintf('Imported %d domain names.', count($domains)));
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user