SpringBoot整合justauth实现多种方式的第三方登陆

时间:2025-04-03 09:05:35
  • <?xml version="1.0" encoding="UTF-8"?>
  • <project xmlns="/POM/4.0.0"
  • xmlns:xsi="http:///2001/XMLSchema-instance"
  • xsi:schemaLocation="/POM/4.0.0 /xsd/maven-4.0.">
  • <modelVersion>4.0.0</modelVersion>
  • <parent>
  • <groupId></groupId>
  • <artifactId>spring-boot-starter-parent</artifactId>
  • <version>2.3.</version>
  • <relativePath/> <!-- lookup parent from repository -->
  • </parent>
  • <groupId></groupId>
  • <artifactId>demo</artifactId>
  • <version>0.0.1-SNAPSHOT</version>
  • <name>demo</name>
  • <description>Demo project for Spring Boot</description>
  • <properties>
  • <>UTF-8</>
  • <>UTF-8</>
  • <>1.8</>
  • <>1.1.0</>
  • </properties>
  • <dependencies>
  • <dependency>
  • <groupId></groupId>
  • <artifactId>spring-boot-starter-web</artifactId>
  • </dependency>
  • <dependency>
  • <groupId></groupId>
  • <artifactId>spring-boot-starter-test</artifactId>
  • <scope>test</scope>
  • </dependency>
  • <!-- 添加适用于生产环境的功能,如性能指标和监测等功能 -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>spring-boot-starter-actuator</artifactId>
  • </dependency>
  • <!-- ====================================================== -->
  • <!-- reids -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>spring-boot-starter-data-redis</artifactId>
  • </dependency>
  • <!-- 对象池,使用redis时必须引入 -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>commons-pool2</artifactId>
  • </dependency>
  • <!-- oauth工具类 -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>justauth-spring-boot-starter</artifactId>
  • <version>${}</version>
  • </dependency>
  • <!-- lombok插件 -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>lombok</artifactId>
  • <optional>true</optional>
  • </dependency>
  • <!-- /artifact//hutool-all -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>hutool-all</artifactId>
  • <version>5.3.8</version>
  • </dependency>
  • <!-- /artifact//guava -->
  • <dependency>
  • <groupId></groupId>
  • <artifactId>guava</artifactId>
  • <version>29.0-jre</version>
  • </dependency>
  • </dependencies>
  • <build>
  • <!-- 注:maven默认是不编译,因此加上如下resources才会生产对应的xml文件 目的:解决mybatis映射关系不对应问题 start =============== -->
  • <resources>
  • <resource>
  • <directory>src/main/java</directory>
  • <includes>
  • <include>**/*.xml</include>
  • </includes>
  • <filtering>false</filtering>
  • </resource>
  • <resource>
  • <directory>src/main/resources</directory>
  • </resource>
  • </resources>
  • <testResources>
  • <testResource>
  • <directory>src/main/java</directory>
  • <includes>
  • <include>**/*.xml</include>
  • </includes>
  • <filtering>false</filtering>
  • </testResource>
  • </testResources>
  • <!-- 注:maven默认是不编译,因此加上如下resources才会生产对应的xml文件 目的:解决mybatis映射关系不对应问题 end =============== -->
  • <plugins>
  • <plugin>
  • <groupId></groupId>
  • <artifactId>spring-boot-maven-plugin</artifactId>
  • </plugin>
  • </plugins>
  • </build>
  • </project>