File: //usr/share/php/Symfony/Bundle/FrameworkBundle/Resources/config/http_client.xml
<?xml version="1.0" ?>
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
<services>
<service id="http_client" class="Symfony\Contracts\HttpClient\HttpClientInterface">
<tag name="monolog.logger" channel="http_client" />
<factory class="Symfony\Component\HttpClient\HttpClient" method="create" />
<argument type="collection" /> <!-- default options -->
<argument /> <!-- max host connections -->
<call method="setLogger">
<argument type="service" id="logger" on-invalid="ignore" />
</call>
</service>
<service id="Symfony\Contracts\HttpClient\HttpClientInterface" alias="http_client" />
<service id="psr18.http_client" class="Symfony\Component\HttpClient\Psr18Client">
<argument type="service" id="http_client" />
<argument type="service" id="Psr\Http\Message\ResponseFactoryInterface" on-invalid="ignore" />
<argument type="service" id="Psr\Http\Message\StreamFactoryInterface" on-invalid="ignore" />
</service>
<service id="Psr\Http\Client\ClientInterface" alias="psr18.http_client" />
</services>
</container>