elastic / elasticsearch-php

Official PHP client for Elasticsearch.
https://www.elastic.co/guide/en/elasticsearch/client/php-api/current/index.html
MIT License
5.26k stars 966 forks source link

Need to unset http proxy #1272

Open abmmhasan opened 1 year ago

abmmhasan commented 1 year ago

Summary of problem or feature request

While requesting I have to unset http proxy, but how to set it during build? I need to call this way.

Code snippet of problem

ClientBuilder::create()
                ->setHosts(["{$conf['host']}:{$conf['port']}"])
                ->build()

System details

ezimuel commented 1 year ago

@abmmhasan can you add more information on the issue? Thanks.

abmmhasan commented 1 year ago

Well, before I call the above I have to do putenv('http_proxy') But this affects everything in that process. So, I wanna do that only for above, how can I do that?