Azure / azure-service-bus-java

☁️ Java client library for Azure Service Bus
https://azure.microsoft.com/services/service-bus
MIT License
60 stars 59 forks source link

Proxy usage of ManagementClient class #392

Open suti211 opened 5 years ago

suti211 commented 5 years ago

My question is the following: The company I work at, uses corporate proxies. I'm working on SpringBoot microservices in Azure. To be able to run these services locally, we need to specify our HTTP and HTTPS proxies in VM options, and everything is fine, well except in case of the ManagementClient. ManagementClient seems not to pick up these proxy settings, and all of the requests sent by it, are timing out.

java.util.concurrent.TimeoutException: Request timeout to "namespace-placeholder".servicebus.windows.net:443 after 30000 ms

Did some research, and it seems ManagementClient's sendManagementHttpRequestAsync() method sends out a request, and at this point proxy settings are not present, so all requests are timing out. As i've seen asynchttpclient's RequestBuilder provides an indirect way to set this up, but it's not used.

Is there a way to set this up which i'm missing?

nemakam commented 5 years ago

@suti211, As you have already mentioned, this hasn't been integrated with Proxy and hasn't been tested. We will add it to our backlog items and plan accordingly. Thanks for opening this issue. Meanwhile, feel free to open a PR.