[OPENAM-16775] Public API access to org.forgerock.openam.core.realms.Realms method(s) Created: 10/Sep/20 Updated: 14/Sep/20 Resolved: 14/Sep/20
|Remaining Estimate:||Not Specified|
|Time Spent:||Not Specified|
|Original Estimate:||Not Specified|
|Support Ticket IDs:|
Specifically the #of method:
returns the realm in Realm type, instead of a String. This is needed when trying to use annotated service but the calling service doesn't support injection.
For example, PAP doesn't support injection. If it needs to access an annotated service, then it needs to call the #getRealmSingleton method:
So, one can use
and then use Realms.of(realm) to get the realm in Realm type.
The workaround is to create a global service and then use #getGlobalSingleton where Realm is not required, but global service is not always an accepted solution.
It's quite unlikely to update PAP to support injection, so making the #of method would be useful.
|Comment by Andy Hall [ 14/Sep/20 ]|
Effort should be focussed in OPENAM-14814