Skip to content

Commit 9970840

Browse files
Nyholmdbu
authored andcommitted
Added a note about no body for GET requests (#131)
Added a note about no body for GET requests
1 parent 5dd9020 commit 9970840

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

clients/buzz-adapter.rst

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,15 @@ Or if you installed the :doc:`discovery </discovery>` layer::
5454

5555
The message factory parameter is mandatory if the discovery layer is not installed.
5656

57+
Be aware
58+
--------
59+
60+
This adapter violates the Liskov substitution principle in a rare edge case. When the adapter is configured to use
61+
Buzz' Curl client, it does not send request bodies for request methods such as GET, HEAD and TRACE. A ``RequestException``
62+
will be thrown if this ever happens.
63+
64+
If you need GET request with a body (e.g. for Elasticsearch) you need to use the Buzz FileGetContents client or choose a different HTTPlug client like Guzzle 6.
65+
5766
.. include:: includes/further-reading-sync.inc
5867

5968
.. _Buzz HTTP client: https://github.com/kriswallsmith/Buzz

spelling_word_list.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@ boolean
55
callables
66
cURL
77
Diactoros
8+
Elasticsearch
89
fallback
910
GitHub
1011
hotfix
12+
Liskov
1113
Symfony
1214
HTTPlug
1315
Ivory

0 commit comments

Comments
 (0)