Added roles to ExternalServiceInfo constructor

This commit is contained in:
Lucio Lelii 2022-04-20 16:25:31 +02:00
parent 4993a52c61
commit c0e1360940
2 changed files with 14 additions and 3 deletions

View File

@ -4,9 +4,10 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [v2.5.0-SNAPSHOT] ## [v2.5.0-SNAPSHOT] - [2022-04-20]
Deprecated AccessTokenProvider, AuthorizationProvider and SecurityTokenProvider [#22871] - Deprecated AccessTokenProvider, AuthorizationProvider and SecurityTokenProvider [#22871]
- Added roles to ExternalService Client info
## [v2.4.0] - [2021-05-21] ## [v2.4.0] - [2021-05-21]

View File

@ -22,10 +22,20 @@ public class ExternalServiceInfo extends ClientInfo{
private String generatedBy; private String generatedBy;
private List<String> roles;
public ExternalServiceInfo(String id, String generatedBy) { public ExternalServiceInfo(String id, String generatedBy) {
super(); super();
this.id = id; this.id = id;
this.generatedBy = generatedBy; this.generatedBy = generatedBy;
this.roles = Collections.emptyList();
}
public ExternalServiceInfo(String id, String generatedBy, List<String> roles) {
super();
this.id = id;
this.generatedBy = generatedBy;
this.roles = roles;
} }
protected ExternalServiceInfo() { protected ExternalServiceInfo() {
@ -43,7 +53,7 @@ public class ExternalServiceInfo extends ClientInfo{
@Override @Override
public List<String> getRoles() { public List<String> getRoles() {
return Collections.emptyList(); return roles;
} }
@Override @Override