By: Conrad Krinock user 19 May 2020 at 12:54 p.m. CDT

5 Responses
Conrad Krinock gravatar
## Background Info I have not run maven for a while, so this might be a stupid question ... for https://github.com/GluuFederation/oxAuth/tree/master/rp-spring-boot, we are able to run successfully: ``` $ mvn clean $ mvn compile $ mvn install $ mvn package ``` ## Error ``` $ mvn spring-boot:run -- details below ``` ## Log ``` $ cd .../oxAuth/rp-spring-boot $ mvn clean ... [INFO] BUILD SUCCESS [INFO] -------------------------------------------------------- mvn compile ... [INFO] BUILD SUCCESS [INFO] -------------------------------------------------------- mvn install ... [INFO] BUILD SUCCESS [INFO] -------------------------------------------------------- mvn package ... [INFO] BUILD SUCCESS [INFO] -------------------------------------------------------- mvn spring-boot:run . ____ _ __ _ _ /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \\/ ___)| |_)| | | | | || (_| | ) ) ) ) ' |____| .__|_| |_|_| |_\__, | / / / / =========|_|==============|___/=/_/_/_/ :: Spring Boot :: (v2.2.0.RELEASE) 2020-05-19 13:26:07.424 INFO 17136 --- [ main] org.gluu.demo.RpSpringBootApplication : Starting RpSpringBootApplication on ConradLpTop2019 with PID 17136 (C:\Conrad_DEV\JavaKnowledgeBase\GluuOAuth2client\oxAuth\rp-spring-boot\target\classes started by conra in C:\Conrad_DEV\JavaKnowledgeBase\GluuOAuth2client\oxAuth\rp-spring-boot) 2020-05-19 13:26:07.424 INFO 17136 --- [ main] org.gluu.demo.RpSpringBootApplication : No active profile set, falling back to default profiles: default 2020-05-19 13:26:09.010 INFO 17136 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat initialized with port(s): 8080 (http) 2020-05-19 13:26:09.025 INFO 17136 --- [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat] 2020-05-19 13:26:09.025 INFO 17136 --- [ main] org.apache.catalina.core.StandardEngine : Starting Servlet engine: [Apache Tomcat/9.0.27] 2020-05-19 13:26:09.174 INFO 17136 --- [ main] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext 2020-05-19 13:26:09.174 INFO 17136 --- [ main] o.s.web.context.ContextLoader : Root WebApplicationContext: initialization completed in 1667 ms 2020-05-19 13:26:09.627 WARN 17136 --- [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'rpSpringBootApplication': Unsatisfied dependency expressed through method 'setContentNegotationStrategy' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.springframework.boot.autoconfigure.web.servlet.WebMvcAutoConfiguration$EnableWebMvcConfiguration': Unsatisfied dependency expressed through method 'setConfigurers' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.springframework.security.config.annotation.web.configuration. OAuth2ClientConfiguration$OAuth2ClientWebMvcSecurityConfiguration': Unsatisfied dependency expressed through method 'setClientRegistrationRepository' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'clientRegistrationRepository' defined in class path resource [org/springframework/boot/autoconfigure/security/oauth2/client/servlet/ OAuth2ClientRegistrationRepositoryConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.security.oauth2.client.registration.InMemoryClientRegistrationRepository]: Factory method 'clientRegistrationRepository' threw exception; nested exception is java.lang.IllegalArgumentException: Unable to resolve Configuration with the provided Issuer of "https://test.gluu.org" 2020-05-19 13:26:09.640 INFO 17136 --- [ main] o.apache.catalina.core.StandardService : Stopping service [Tomcat] 2020-05-19 13:26:09.657 INFO 17136 --- [ main] ConditionEvaluationReportLoggingListener : Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled. 2020-05-19 13:26:09.674 ERROR 17136 --- [ main] o.s.boot.SpringApplication : Application run failed ``` ## Request Please advise what are the correct mvn commands to run this spring boot app

By Michael Schwartz staff 19 May 2020 at 1:38 p.m. CDT

Michael Schwartz gravatar
I'm assigning this to a new engineer we are onboarding. He is going to update the Readme with better instructions and add dynamic client registration. BTW, I think the key line in the error log is: ``` Unable to resolve Configuration with the provided Issuer of "https://test.gluu.org" ``` Have you updated your local hosts file to point `test.gluu.org` to the IP address of your server? Does this return the config page: ``` $ curl --insecure https://test.gluu.org/.well-known/openid-configuration ```

By Conrad Krinock user 19 May 2020 at 1:58 p.m. CDT

Conrad Krinock gravatar
Thanks Mike Yes I updated my local hosts file. I can access my Gluu-AS dashboard via https://test.gluu.org in my Windows10 pc browser. - Gluu-AS is on a (new) ubuntu server on my home office network - My Windows10 PC is a separate host on my home officenetwork Here's the result of the curl on my Windows10 PC: ``` $ curl --insecure https://test.gluu.org/.well-known/openid-configuration % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 5054 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0{ "request_parameter_supported" : true, "token_revocation_endpoint" : "https://test.gluu.org/oxauth/restv1/revoke", "introspection_endpoint" : "https://test.gluu.org/oxauth/restv1/introspection", "claims_parameter_supported" : false, "check_session_iframe" : "https://test.gluu.org/oxauth/opiframe.htm", ... ```

By Michael Schwartz staff 19 May 2020 at 2:15 p.m. CDT

Michael Schwartz gravatar
``` Unable to resolve Configuration with the provided Issuer of "https://test.gluu.org" ``` Maybe they want the whole config url, like `https://test.gluu.org/.well-known/openid-configuration`

By Conrad Krinock user 20 May 2020 at 6:56 a.m. CDT

Conrad Krinock gravatar
## issuer-url I changed the "issuer-url" in my application.yml to: issuer-uri: https://test.gluu.org/.well-known/openid-configuration and re-ran the mvn clean compile install package but still getting the same errors when I execute mvn spring-boot:run. ## Hypothesis 1: very first error is: Error creating bean with name 'rpSpringBootApplication' However this file exists on my PC C:\Users\conra\.m2\repository\org\gluu\rp-spring-boot\4.2.0-SNAPSHOT\rp-spring-boot-4.2.0-SNAPSHOT.war ## Hypothesis 2: I'm using of of the EXISTING clients on my Gluu-AS, namely: Gluu RO OpenID Client 1701.2fc282d4-1f7c-4781-970f-ae22d4673fea Going to try creating a new client based on the email Mike sent me Tue 5/19/2020 9:44 AM

By Conrad Krinock user 22 May 2020 at 12:53 p.m. CDT

Conrad Krinock gravatar
Resolved / Awesome / Hallelujah