|
@@ 375-383 (lines=9) @@
|
| 372 |
|
private function configureAutoDiscoveryClients(ContainerBuilder $container, array $config) |
| 373 |
|
{ |
| 374 |
|
$httpClient = $config['discovery']['client']; |
| 375 |
|
if ('auto' !== $httpClient) { |
| 376 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_client'); |
| 377 |
|
$container->removeDefinition('httplug.collector.auto_discovered_client'); |
| 378 |
|
|
| 379 |
|
if (!empty($httpClient)) { |
| 380 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_client', $httpClient); |
| 381 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_client')->setPublic(false); |
| 382 |
|
} |
| 383 |
|
} |
| 384 |
|
|
| 385 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 386 |
|
if ('auto' !== $asyncHttpClient) { |
|
@@ 386-394 (lines=9) @@
|
| 383 |
|
} |
| 384 |
|
|
| 385 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 386 |
|
if ('auto' !== $asyncHttpClient) { |
| 387 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_async'); |
| 388 |
|
$container->removeDefinition('httplug.collector.auto_discovered_async'); |
| 389 |
|
|
| 390 |
|
if (!empty($asyncHttpClient)) { |
| 391 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_async', $asyncHttpClient); |
| 392 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_async')->setPublic(false); |
| 393 |
|
} |
| 394 |
|
} |
| 395 |
|
|
| 396 |
|
if (null === $httpClient && null === $asyncHttpClient) { |
| 397 |
|
$container->removeDefinition('httplug.strategy'); |