Please wait...

小波Note

四川 · 成都市12 ℃
English

Spring Boot Gradle Dependencies Config

成都 (cheng du)6/10/2024, 2:47:01 PM2.85kEstimated reading time 9 minFavoriteCtrl + D / ⌘ + D
cover
IT FB(up 主)
Back-end development engineer
build.gradle
        plugins {
    id 'java'
    id 'org.springframework.boot' version '3.3.2'
    id 'io.spring.dependency-management' version '1.1.6'
}

group = 'com.xxx'
version '1.0.0'

java {
    sourceCompatibility = JavaVersion.VERSION_21
    targetCompatibility = JavaVersion.VERSION_21
}

repositories {
    repositories {
        mavenLocal()
        maven {
            url 'https://maven.aliyun.com/nexus/content/groups/public/'
        }
        mavenCentral()
    }
    mavenCentral()
}

dependencies {

    // Spring boot 依赖
    implementation 'org.springframework.boot:spring-boot-starter-web'
    implementation 'org.springframework.boot:spring-boot-starter-aop'
    implementation 'org.springframework.boot:spring-boot-starter-security'
//    implementation 'org.springframework.boot:spring-boot-starter-data-redis'
    implementation 'org.springframework.boot:spring-boot-starter-cache'
    implementation 'org.springframework.boot:spring-boot-starter-mail'
    implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
    implementation 'org.springframework.boot:spring-boot-starter-validation'
    implementation 'org.springframework.boot:spring-boot-starter-websocket'
    implementation 'org.springframework.boot:spring-boot-starter-data-jpa'
    implementation 'org.springframework.boot:spring-boot-starter-test'

    implementation 'com.baomidou:mybatis-plus-spring-boot3-starter:3.5.7'
    implementation 'com.baomidou:mybatis-plus-generator:3.5.7'

    // freemarker
    implementation 'org.freemarker:freemarker:2.3.33'

    // Lombok 支持
    implementation 'org.projectlombok:lombok:1.18.30'
    annotationProcessor 'org.projectlombok:lombok:1.18.30'

    // fastjson2
    implementation 'com.alibaba.fastjson2:fastjson2:2.0.21'

    // Mysql Driver
    implementation 'mysql:mysql-connector-java:8.0.33'

    // Dozer
    implementation 'com.github.dozermapper:dozer-core:7.0.0'

    // HttpClient
    implementation 'org.apache.httpcomponents:httpclient:4.5.14'

    // Tencent Cos
    implementation 'com.qcloud:cos_api:5.6.217'
    implementation 'com.qcloud:cos-sts_api:3.1.1'

    // redisson
    implementation 'org.redisson:redisson-spring-boot-starter:3.25.1'

    // geoIp2
    implementation 'com.maxmind.geoip2:geoip2:4.2.0'

    // xml
    implementation 'dom4j:dom4j:1.6.1'

    // JWT 支持
    implementation 'io.jsonwebtoken:jjwt:0.9.1'

    // API Document
    implementation 'io.springfox:springfox-core:3.0.0'
    implementation 'io.springfox:springfox-swagger2:3.0.0'
    implementation 'io.springfox:springfox-swagger-ui:3.0.0'

//    testImplementation platform('org.junit:junit-bom:5.9.1')
//    testImplementation 'org.junit.jupiter:junit-jupiter'
}

test {
    useJUnitPlatform()
}