|
@@ 458-466 (lines=9) @@
|
| 455 |
|
private function configureAutoDiscoveryClients(ContainerBuilder $container, array $config) |
| 456 |
|
{ |
| 457 |
|
$httpClient = $config['discovery']['client']; |
| 458 |
|
if ('auto' !== $httpClient) { |
| 459 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_client'); |
| 460 |
|
$container->removeDefinition('httplug.collector.auto_discovered_client'); |
| 461 |
|
|
| 462 |
|
if (!empty($httpClient)) { |
| 463 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_client', $httpClient); |
| 464 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_client')->setPublic(false); |
| 465 |
|
} |
| 466 |
|
} |
| 467 |
|
|
| 468 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 469 |
|
if ('auto' !== $asyncHttpClient) { |
|
@@ 469-477 (lines=9) @@
|
| 466 |
|
} |
| 467 |
|
|
| 468 |
|
$asyncHttpClient = $config['discovery']['async_client']; |
| 469 |
|
if ('auto' !== $asyncHttpClient) { |
| 470 |
|
$container->removeDefinition('httplug.auto_discovery.auto_discovered_async'); |
| 471 |
|
$container->removeDefinition('httplug.collector.auto_discovered_async'); |
| 472 |
|
|
| 473 |
|
if (!empty($asyncHttpClient)) { |
| 474 |
|
$container->setAlias('httplug.auto_discovery.auto_discovered_async', $asyncHttpClient); |
| 475 |
|
$container->getAlias('httplug.auto_discovery.auto_discovered_async')->setPublic(false); |
| 476 |
|
} |
| 477 |
|
} |
| 478 |
|
|
| 479 |
|
if (null === $httpClient && null === $asyncHttpClient) { |
| 480 |
|
$container->removeDefinition('httplug.strategy'); |