Skip to content

Commit 797d8cc

Browse files
committed
Lint and versionadded
1 parent 9563643 commit 797d8cc

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

http_client.rst

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -734,12 +734,13 @@ each retry.
734734
Retry over different uris
735735
.........................
736736

737+
.. versionadded:: 6.3
738+
The multiple ``base_uri`` feature was added in Symfony 6.3.
739+
737740
The ``RetryableHttpClient`` can be configured to use multiple base URIs. This
738741
feature provides increased flexibility and reliability for making HTTP
739742
requests. Pass an array of base URIs as option ``base_uri`` when making a
740-
request:
741-
742-
.. code-block:: php
743+
request::
743744

744745
$response = $client->request('GET', 'foo-bar', [
745746
'base_uri' => [
@@ -754,9 +755,7 @@ When the number of retries is higher than the number of base URIs, the
754755
last base URI will be used for remaining retries.
755756

756757
If you want to shuffle the order of base URIs for each retry attempt, nest the
757-
base URIs you want to shuffle in an additional array:
758-
759-
.. code-block:: php
758+
base URIs you want to shuffle in an additional array::
760759

761760
$response = $client->request('GET', 'foo-bar', [
762761
'base_uri' => [
@@ -778,9 +777,7 @@ By using a nested array for the base URI, you can use this feature
778777
to distribute the load among many nodes in a cluster of servers.
779778

780779
You can also configure the array of base URIs using the ``withOptions()``
781-
method:
782-
783-
.. code-block:: php
780+
method::
784781

785782
$client = $client->withOptions(['base_uri' => [
786783
'http://example.com/a/',

0 commit comments

Comments
 (0)