public LPSubjectReference obtain(SubjectReference reference) {
        Objects.requireNonNull(reference, "reference");
        if (reference instanceof LPSubjectReference) {
            return (LPSubjectReference) reference;
        } else {
            return obtain(reference.collectionIdentifier(), reference.subjectIdentifier());
        }
    }
Cache based factory for SubjectReferences.

Using a factory and caching here makes the Subject cache in SubjectReference
more effective. This reduces the no. of times i/o is executed due to resolve calls
within the SubjectReference.

It's perfectly ok if two instances of the same SubjectReference exist. (hence the 1 hour expiry)
sponge/sponge-service/src/main/java/me/lucko/luckperms/sponge/service/reference/SubjectReferenceFactory.java