mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[AAE-9311] Use new micro service ingress for people/group (#7708)
* [AAE-9311] Use new micro service ingress for people/group * [AAE-9311] change ingress for user-access-service * [AAE-9311] fix unit test * Trigger travis * [AAE-9311] fix unit test
This commit is contained in:
@@ -152,7 +152,7 @@ describe('UserAccessService', () => {
|
||||
appConfigService.config.bpmHost = fakeIdentityHost;
|
||||
await userAccessService.fetchUserAccess();
|
||||
|
||||
expect(getAccessFromApiSpy).toHaveBeenCalledWith({ url: `${fakeIdentityHost}/modeling-service/v1/identity/roles` });
|
||||
expect(getAccessFromApiSpy).toHaveBeenCalledWith({ url: `${fakeIdentityHost}/identity-adapter-service/v1/roles` });
|
||||
});
|
||||
|
||||
it('should not fetch the access from the API if is not configured with OAUTH', async () => {
|
||||
|
@@ -22,7 +22,7 @@ import { UserAccessModel } from '../models/user-access.model';
|
||||
import { AppConfigService } from '../app-config/app-config.service';
|
||||
import { OAuth2Service } from './oauth2.service';
|
||||
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'modeling-service';
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'identity-adapter-service';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
@@ -52,7 +52,7 @@ export class UserAccessService {
|
||||
}
|
||||
|
||||
private async fetchAccessFromApi() {
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/identity/roles`;
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/roles`;
|
||||
await this.oAuth2Service.get({ url })
|
||||
.toPromise()
|
||||
.then((response: UserAccessModel) => {
|
||||
|
@@ -23,7 +23,7 @@ import { IdentityGroupServiceInterface } from './identity-group.service.interfac
|
||||
import { IdentityGroupFilterInterface } from './identity-group-filter.interface';
|
||||
import { IdentityGroupModel } from '../models/identity-group.model';
|
||||
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'modeling-service';
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'identity-adapter-service';
|
||||
|
||||
@Injectable({ providedIn: 'root' })
|
||||
export class IdentityGroupService implements IdentityGroupServiceInterface {
|
||||
@@ -72,7 +72,7 @@ export class IdentityGroupService implements IdentityGroupServiceInterface {
|
||||
}
|
||||
|
||||
private invokeIdentityGroupApi(): Observable<IdentityGroupModel[]> {
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/identity/groups`;
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/groups`;
|
||||
return this.oAuth2Service.get({ url, queryParams: this.queryParams });
|
||||
}
|
||||
|
||||
|
@@ -27,7 +27,7 @@ import { IdentityUserServiceInterface } from './identity-user.service.interface'
|
||||
import { IdentityUserModel } from '../models/identity-user.model';
|
||||
import { IdentityUserFilterInterface } from './identity-user-filter.interface';
|
||||
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'modeling-service';
|
||||
const IDENTITY_MICRO_SERVICE_INGRESS = 'identity-adapter-service';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
@@ -110,7 +110,7 @@ export class IdentityUserService implements IdentityUserServiceInterface {
|
||||
}
|
||||
|
||||
private invokeIdentityUserApi(): Observable<any> {
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/identity/users`;
|
||||
const url = `${this.identityHost}/${IDENTITY_MICRO_SERVICE_INGRESS}/v1/users`;
|
||||
return this.oAuth2Service.get({ url, queryParams: this.queryParams });
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user