ahgittin commented on a change in pull request #1171:
URL: https://github.com/apache/brooklyn-server/pull/1171#discussion_r631766664
##########
File path:
core/src/main/java/org/apache/brooklyn/core/config/external/vault/VaultExternalConfigSupplier.java
##########
@@ -131,27 +134,21 @@ public String get(String key) {
protected JsonObject apiGetRetryable(String path, Map<String, String>
headers, int recoverTryCount) {
try {
- if (Strings.isBlank(headers.get("X-Vault-Token"))){
+ if (Strings.isBlank(headers.get("X-Vault-Token"))) {
String currentToken = initAndLogIn(config);
- if (Strings.isBlank(currentToken)){
+ if (Strings.isBlank(currentToken)) {
throw new IllegalStateException("Vault sealed or
unavailable.");
}
- headers =
MutableMap.copyOf(headers).add("X-Vault-Token",currentToken);
+ headers = MutableMap.copyOf(headers).add("X-Vault-Token",
currentToken);
}
return apiGet(path, headers);
- }
- catch (Exception e){
+ } catch (Exception e) {
Review comment:
this (new way) is what almost everyone on the project does
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]