| The authenticator configured through xwiki.authentication.authclass in xwiki.cfg (org.xwiki.contrib.oidc.auth.OIDCAuthServiceImpl) holds the implementation of the OpenID Connect authentication and gets the components it needs once, when it's created. Since XWiki keeps the same instance as long as the class itself does not change, it keeps using those component instances even when they are registered again (for example when the Extension Manager reloads extensions), and then works with disposed components (see OIDC-323). The idea is to invert the current logic:
- move the implementation to the oidc authenticator component (OIDCAuthService), which gets its dependencies injected
- make OIDCAuthServiceImpl forward each call to the oidc authenticator component currently registered
|