* Revert "Revert "Added props""
This reverts commit f40ad30d39.
* Fixed NPE
* Added tests
* Formatting
* Tests again
* Fixed NRE
* Upgrade mockito to fix tests
* Added according to spec
* Fallback to env
* Align name
* format
* format
* format
* Fixed tests
* Some comments
* Moved header logic away.
* Formatter
* Fixed null
* Removed append method
* FFormat
* remove unrelated test
* Optimize imports
* Align param order with .net
* format
* Naming
* Use real url
* PR fixes
* public
* format
* Update Utils.java
* start
* matcher
* clean
* matcher
* dragt
* not work
* Tests and all works well
* Tests and all works well
* clean all dirt
* fix format
* fix formatClientImpl
* databind conflict
* Formatting
* fix NPE
comments
* comment
* revert e2e
* fix NPEs !!
* format
Co-authored-by: Ohad Bitton <ohbitton@microsoft.com>
Co-authored-by: AsafMah <asafmahlev@microsoft.com>
* * Update README with new maven version to use
* Credentials provider is not supported in the new revision. Removed the reference
* * Add maven version badge instead of hardcoding the version
* * Add maven version so that it is easy to integrate into POM
* * Add maven version so that it is easy to integrate into POM
Co-authored-by: AsafMah <asafmahlev@microsoft.com>
* Improve wrong endpoint detection:
- Improve exception handling: if retrieveServiceType() can't determine the endpoint's ServiceType, it shouldn't throw an (uncaught, no less) exception but instead should return null
- Improve message to be clearer and more actionable for the user
- Log warnings instead of errors if we can't suggest the right URL
* Black!
* Black!
* Per code review
* Black!
* Fix black
* Fix black
Co-authored-by: AsafMah <asafmahlev@microsoft.com>
* Black: Propose rolling back requiring there be no newline after a field's annotation. Alternatively, I propose requiring that there *be* a newline after a field's annotation.
As discussed previously, my perspective is that if one code style isn't clearly better than alternatives, the best approach is to let the devs decide. We don't need all aspects of code style to be 100% conforming in all ways, and taking away freedom unnecessarily from devs makes devs sad.
* Fix black
* Fix black
Co-authored-by: AsafMah <asafmahlev@microsoft.com>
[This PR](https://github.com/Azure/azure-kusto-java/pull/185/) added support for localhost in the Kusto client. This is extremely useful to mock ADX using Wiremock for example.
There seems to be one last issue however in `com.microsoft.azure.kusto.data.Utils.parseUriFromUrlString`. A typical input `url` would be `http://localhost:[port]/v2/rest/query`; however, when parsed, the `cleanUrl` host is `localhost` and not `http://localhost`.
The fix in this PR is to use the exact same logic as the ClientImpl constructor which is:
```java
aadAuthenticationHelper = clusterUrl.toLowerCase().startsWith(CloudInfo.LOCALHOST) ? null : TokenProviderFactory.createTokenProvider(csb, httpClient);
```
Co-authored-by: AsafMah <asafmahlev@microsoft.com>
* CloudInfoHttp - first attempt
* Fixed firstPartyUrl and enabled new http client
* -Fixed test
-Added http client options to ingest clients
* Formatting
* Added comments and minor refactorings
* Fixed method
* Transfer httpclient in the provider ctor
* Change http client ctor to accept system
* Added proxy props
* Fixed NREs
* Added proxy and props support to missing locations
* Update README.md
* Remove auth until next storage version
* format
* Fixed missing exception
* appendIfMissing