yashmayya commented on code in PR #18456:
URL: https://github.com/apache/pinot/pull/18456#discussion_r3222798213
##########
pinot-common/src/main/java/org/apache/pinot/common/auth/UrlAuthProvider.java:
##########
@@ -57,7 +57,11 @@ public UrlAuthProvider(AuthConfig authConfig) {
try {
_header = AuthProviderUtils.getOrDefault(authConfig, HEADER,
HttpHeaders.AUTHORIZATION);
_prefix = AuthProviderUtils.getOrDefault(authConfig, PREFIX, "Bearer");
- _url = new URL(authConfig.getProperties().get(URL).toString());
+ Object urlValue = authConfig.getProperties().get(URL);
+ if (urlValue == null) {
+ throw new IllegalArgumentException("Missing required auth config
property: " + URL);
+ }
Review Comment:
nit: shouldn't this be outside the try block?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]