|
@@ 437-445 (lines=9) @@
|
| 434 |
|
private function configureAutoDiscoveryClients(ContainerBuilder $container, array $config) |
| 435 |
|
{ |
| 436 |
|
$httpClient = $config['discovery']['client']; |
| 437 |
|
if ('auto' !== $httpClient) { |
| 438 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_client'); |
| 439 |
|
$container->removeDefinition('httplug.collector.auto_discovered_client'); |
| 440 |
|
|
| 441 |
|
if (!empty($httpClient)) { |
| 442 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_client', $httpClient); |
| 443 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_client')->setPublic(false); |
| 444 |
|
} |
| 445 |
|
} |
| 446 |
|
|
| 447 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 448 |
|
if ('auto' !== $asyncHttpClient) { |
|
@@ 448-456 (lines=9) @@
|
| 445 |
|
} |
| 446 |
|
|
| 447 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 448 |
|
if ('auto' !== $asyncHttpClient) { |
| 449 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_async'); |
| 450 |
|
$container->removeDefinition('httplug.collector.auto_discovered_async'); |
| 451 |
|
|
| 452 |
|
if (!empty($asyncHttpClient)) { |
| 453 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_async', $asyncHttpClient); |
| 454 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_async')->setPublic(false); |
| 455 |
|
} |
| 456 |
|
} |
| 457 |
|
|
| 458 |
|
if (null === $httpClient && null === $asyncHttpClient) { |
| 459 |
|
$container->removeDefinition('httplug.strategy'); |