Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to instantiate AzureADIdentityOAuthProvider #2

Closed
gdelhumeau opened this issue Sep 27, 2021 · 6 comments
Closed

Failed to instantiate AzureADIdentityOAuthProvider #2

gdelhumeau opened this issue Sep 27, 2021 · 6 comments
Assignees
Labels
Type: Bug Something isn't working
Milestone

Comments

@gdelhumeau
Copy link

gdelhumeau commented Sep 27, 2021

Hello.

I have an XWiki instance, on which the "Microsoft Azure Active Directory Single Sign-On (SSO) (Pro)" app is installed on the main wiki, with its dependencies.

However, when I try to enable the SSO, I get the following stacktrace in the logs:

org.xwiki.component.manager.ComponentLookupException: Can't find descriptor for the component with type [interface com.xwiki.identityoauth.IdentityOAuthProvider] and hint [Azur
eAD]
        at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:212)
        at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:210)
        at org.xwiki.component.internal.multi.DelegateComponentManager.getInstance(DelegateComponentManager.java:83)
        at org.xwiki.component.internal.multi.DelegateComponentManager.getInstance(DelegateComponentManager.java:83)
        at org.xwiki.component.internal.multi.DelegateComponentManager.getInstance(DelegateComponentManager.java:83)
        at org.xwiki.component.internal.multi.DelegateComponentManager.getInstance(DelegateComponentManager.java:83)
        at org.xwiki.component.internal.multi.DelegateComponentManager.getInstance(DelegateComponentManager.java:83)
        at com.xwiki.identityoauth.internal.DefaultIdentityOAuthManager.rebuildProviders(DefaultIdentityOAuthManager.java:217)
        at com.xwiki.identityoauth.internal.DefaultIdentityOAuthManager.reloadConfig(DefaultIdentityOAuthManager.java:292)
        at com.xwiki.identityoauth.internal.IdentityOAuthEventListener.onEvent(IdentityOAuthEventListener.java:94)
        at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:320)
        at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:285)
        at com.xpn.xwiki.XWiki.afterSave(XWiki.java:1997)
        at com.xpn.xwiki.XWiki.saveDocument(XWiki.java:2073)
        at com.xpn.xwiki.web.SaveAction.save(SaveAction.java:270)
        at com.xpn.xwiki.web.SaveAndContinueAction.doWrappedAction(SaveAndContinueAction.java:97)
        at com.xpn.xwiki.web.SaveAndContinueAction.action(SaveAndContinueAction.java:170)
        at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:588)
        at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:283)
        at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:425)
        at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:228)
        at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)
        at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:462)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:122)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.xwiki.wysiwyg.filter.ConversionFilter.doFilter(ConversionFilter.java:109)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.xwiki.container.servlet.filters.internal.SetHTTPHeaderFilter.doFilter(SetHTTPHeaderFilter.java:63)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.xwiki.container.servlet.filters.internal.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:208)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.xwiki.container.servlet.filters.internal.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:111)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.xwiki.resource.servlet.RoutingFilter.doFilter(RoutingFilter.java:132)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
        at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:688)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
        at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:747)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
        at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:367)
        at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
        at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1639)
        at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.base/java.lang.Thread.run(Thread.java:829)
@polx
Copy link
Contributor

polx commented Sep 27, 2021

Hello @gdelhumeau ,

What means "activate SSO": activate the extension?

Can't find descriptor for the component with type [interface com.xwiki.identityoauth.IdentityOAuthProvider] is generally a class-not-found exception. Which JVM are you running and is there no class-not-found-exception or similar?

thanks

paul

@gdelhumeau
Copy link
Author

Hello @gdelhumeau ,

What means "activate SSO": activate the extension?

I mean clicking there and then into the "save" button:
Capture d’écran 2021-09-27 à 15 40 04

Can't find descriptor for the component with type [interface com.xwiki.identityoauth.IdentityOAuthProvider] is generally a class-not-found exception. Which JVM are you running and is there no class-not-found-exception or similar?

I don't see similar problems. We will try to restart of the instance as soon as we can.

thanks

paul

@polx
Copy link
Contributor

polx commented Sep 27, 2021

Which JVM is playing?

@gdelhumeau
Copy link
Author

openjdk version "11.0.11" 2021-04-20
OpenJDK Runtime Environment (build 11.0.11+9-post-Debian-1deb10u1)
OpenJDK 64-Bit Server VM (build 11.0.11+9-post-Debian-1deb10u1, mixed mode, sharing)

@polx
Copy link
Contributor

polx commented Oct 22, 2021

I could reproduce this on a tomcat locally (jdk 11, macos)

@polx polx self-assigned this Oct 22, 2021
@polx polx added the Type: Bug Something isn't working label Oct 22, 2021
@polx
Copy link
Contributor

polx commented Oct 22, 2021

The case where I could reproduce it has been fixed by making the IdentityOAuthAuthService of the Default IdentityOAuthManager a provided injection.

polx added a commit that referenced this issue Oct 26, 2021
… reinstall on farm bug, and (worst) #2: Failed to instantiate AzureADIdentityOAuthProvider.
@mflorea mflorea added this to the 1.4 milestone Oct 29, 2021
@mflorea mflorea closed this as completed Oct 29, 2021
@polx polx modified the milestones: 1.4, 1.5 Nov 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants