With deprecation and possible removal of \GuzzleHttp\Client::getConfig it will become impossible to manipulate HandlerStack of Guzzle client after it has been created. https://github.com/guzzle/guzzle/issues/2514
My use case is adding additional handler to HandlerStack in custom ShopApiClient to have it to retry request when hitting API limits.
Hi @jszczypk ,
I created an internal ticket and we will take this into account when preparing the next release of the Magento 2 seller PHP SDK.
Thank you for your feedback.
Hi,
With deprecation and possible removal of \GuzzleHttp\Client::getConfig it will become impossible to manipulate HandlerStack of Guzzle client after it has been created. https://github.com/guzzle/guzzle/issues/2514
My use case is adding additional handler to HandlerStack in custom ShopApiClient to have it to retry request when hitting API limits.
In \Mirakl\Core\Client\AbstractApiClient stack is hardcoded and it is not possible to extend getDefaultClient.
My suggestion is to add function getDefaultClientParams that will provide parameter to \GuzzleHttp\Client constructor.
Best regards, Janusz