BingAds / BingAds-PHP-SDK

Other
56 stars 46 forks source link

Provide a mechanism that allows to pass custom options to SoapClient #146

Closed juanparati closed 3 years ago

juanparati commented 3 years ago

In the AuthHelper sample, there some "ini_set" sentences that will modify the global behavior of the SoapClient.

It's a bad practice to set global configuration in runtime because it can pollute the behavior of other SoapClient instances that are not related to BingAds.

A solution to this problem it could be allow to provide a method that allow to pass custom options to the SoapClient, so it could be possible to modify the cache options directly on the SoapClient instance used by BingAds.

See SoapClient options for more details.

leongersen commented 3 years ago

I'd like to chime in to this; as of March 8th, we're seeing a large number of connection timeouts while attempting to call the API. There isn't currently an accessible way to set the connection_timeout option when constructing the \SoapClient.

SoapClient::__doRequest(): connect() failed: Connection timed out

eric-urban commented 3 years ago

@juanparati and @leongersen - We will take this up as a priority: "allow to pass custom options to the SoapClient". The AuthHelper sample might remain unmodified since its an example and your application shouldn't have any dependencies on it.

eric-urban commented 3 years ago

@juanparati and @leongersen - Wanted to provide an update that we are actively working on this feature request. We'll follow up again.

eric-urban commented 3 years ago

@juanparati and @leongersen - The options are available with release 13.0.9. Please reach out with any follow up questions.

leongersen commented 3 years ago

I noticed this was in the latest release, thanks!