SUPPORT-9001: refactor
This commit is contained in:
parent
891a643fb4
commit
f0936bf493
3 changed files with 3 additions and 6 deletions
|
|
@ -85,8 +85,7 @@ public class ErvuUserGridLoadService extends Behavior implements GridService {
|
|||
|
||||
HttpRequest request = HttpRequest.newBuilder()
|
||||
.uri(UriComponentsBuilder.fromHttpUrl(ervuUrl)
|
||||
.pathSegment(PathConstant.ACCOUNTS_PATH)
|
||||
.pathSegment(FILTER_PATH)
|
||||
.pathSegment(PathConstant.ACCOUNTS_PATH, FILTER_PATH)
|
||||
.build().toUri())
|
||||
.header(HttpHeaders.CONTENT_TYPE, "application/json")
|
||||
.header(HttpHeaders.AUTHORIZATION, "Bearer " + securityContext.getToken())
|
||||
|
|
|
|||
|
|
@ -36,8 +36,7 @@ public class RoleServiceImpl extends AbstractUserDataService {
|
|||
private List<Role> fetchRolesByAccountId(Object accountId) throws IOException, InterruptedException {
|
||||
String url = UriComponentsBuilder.fromHttpUrl(ervuUrl)
|
||||
.path(PathConstant.ACCOUNTS_PATH)
|
||||
.pathSegment(accountId.toString())
|
||||
.pathSegment(ROLES)
|
||||
.pathSegment(accountId.toString(), ROLES)
|
||||
.toUriString();
|
||||
|
||||
HttpResponse<String> response = sendGetRequest(url);
|
||||
|
|
|
|||
|
|
@ -34,8 +34,7 @@ public class UserCredentialsServiceIpml extends AbstractUserDataService {
|
|||
private List<Credential> fetchCredentialsByPersonId(Object personId) throws IOException, InterruptedException {
|
||||
String url = UriComponentsBuilder.fromHttpUrl(ervuUrl)
|
||||
.path(PathConstant.PERSONS_PATH)
|
||||
.pathSegment(personId.toString())
|
||||
.pathSegment(CREDENTIALS)
|
||||
.pathSegment(personId.toString(), CREDENTIALS)
|
||||
.toUriString();
|
||||
|
||||
HttpResponse<String> response = sendGetRequest(url);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue