JAVA-30693 :- Upgrade Spring Cloud vault to latest Spring Cloud (#15746)

This commit is contained in:
Amit Pandey 2024-02-23 17:27:46 +05:30 committed by GitHub
parent d64c084623
commit 1a94ba4005
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 4 additions and 4 deletions

View File

@ -77,7 +77,7 @@
</build>
<properties>
<spring-cloud.version>2020.0.3</spring-cloud.version>
<spring-cloud.version>2023.0.0</spring-cloud.version>
</properties>
</project>

View File

@ -18,7 +18,7 @@ public class AccountResource {
Account acc = repo.findById(id).orElse(null);
if ( acc != null ) {
return new ResponseEntity<Account>(acc, HttpStatus.OK);
return new ResponseEntity<>(acc, HttpStatus.OK);
}
else {
return new ResponseEntity<>(HttpStatus.NOT_FOUND);

View File

@ -28,10 +28,10 @@ public class SecretResource {
String value = env.getProperty(key);
if ( value != null ) {
return new ResponseEntity<String>(value, HttpStatus.OK);
return new ResponseEntity<>(value, HttpStatus.OK);
}
else {
return new ResponseEntity<String>("not found", HttpStatus.NOT_FOUND);
return new ResponseEntity<>("not found", HttpStatus.NOT_FOUND);
}
}
}