authserver icon indicating copy to clipboard operation
authserver copied to clipboard

Upgrade to spring-boot 2

Open data-mind opened this issue 8 years ago • 2 comments

I have problem when upgrading this project to spring-boot 2.

First of all when upgrade spring-boot-starter-parent to

<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.0.0.M7</version>
<relativePath /> <!-- lookup parent from repository -->

spring-security-oauth2 and spring-security-jwt are not available anymore so I set version manually like this:

<groupId>org.springframework.security.oauth</groupId>
<artifactId>spring-security-oauth2</artifactId>
<version>2.2.1.RELEASE</version>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-jwt</artifactId>
<version>1.0.9.RELEASE</version>

I also remove tests to build project with success. But when I run project as spring-boot application I got exception:

No qualifying bean of type 'org.springframework.security.authentication.AuthenticationManager' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}

data-mind avatar Jan 24 '18 18:01 data-mind

You need to add spring-security-oauth2-autoconfigure to your classpath.

Ref: https://docs.spring.io/spring-security-oauth2-boot/docs/current-SNAPSHOT/reference/htmlsingle/

hamit avatar Mar 22 '18 11:03 hamit

Could the maintainer of this sample project upgrade the code to spring-boot 2 ?

kuchaguangjie avatar Aug 06 '20 11:08 kuchaguangjie