plugins {
    id "java"
    id "maven-publish"
    id "idea"
    id "eclipse"
    alias(libs.plugins.gradle.git.properties)
    alias(libs.plugins.spring.boot)
    id "jhipster.docker-conventions"
    id "jhipster.code-quality-conventions"
    id "org.liquibase.gradle"
    id "jhipster.node-gradle-conventions"
    // jhipster-needle-gradle-plugins - JHipster will add additional gradle plugins here
}

group = "it.sw.pa.comune.artegna"
version = "0.0.1-SNAPSHOT"

description = ""

java {
    sourceCompatibility=17
    targetCompatibility=17
}
assert System.properties["java.specification.version"] == "17" || "21" || "25"

repositories {
    mavenCentral()
    // Local maven repository is required for libraries built locally with maven like development jhipster-bom.
    // mavenLocal()
    // jhipster-needle-gradle-repositories - JHipster will add additional repositories
}

apply from: "gradle/spring-boot.gradle"
apply from: "gradle/liquibase.gradle"
// jhipster-needle-gradle-apply-from - JHipster will add additional gradle scripts to be applied here

idea {
    module {
        excludeDirs += files("node_modules")
    }
}

eclipse {
    sourceSets {
        main {
            java {
                srcDirs += ["build/generated/sources/annotationProcessor/java/main"]
            }
        }
    }
}

dependencies {
    implementation libs.jhipster.framework
    implementation libs.mapstruct
    implementation libs.springdoc.openapi.starter.webmvc.api
    implementation "org.springframework.boot:spring-boot-loader-tools"
    implementation "org.springframework.boot:spring-boot-starter"
    implementation "org.springframework.boot:spring-boot-starter-actuator"
    implementation "org.springframework.boot:spring-boot-starter-aop"
    implementation "org.springframework.boot:spring-boot-starter-cache"
    implementation "org.springframework.boot:spring-boot-starter-data-jpa"
    implementation "org.springframework.boot:spring-boot-starter-mail"
    implementation "org.springframework.boot:spring-boot-starter-security"
    implementation "org.springframework.boot:spring-boot-starter-thymeleaf"
    implementation "org.springframework.boot:spring-boot-starter-tomcat"
    implementation "org.springframework.boot:spring-boot-starter-validation"
    implementation "org.springframework.boot:spring-boot-starter-web"
    implementation "org.springframework.security:spring-security-data"
    implementation "com.fasterxml.jackson.datatype:jackson-datatype-hibernate6"
    implementation "com.fasterxml.jackson.datatype:jackson-datatype-hppc"
    implementation "com.fasterxml.jackson.datatype:jackson-datatype-jsr310"
    implementation "com.fasterxml.jackson.module:jackson-module-jaxb-annotations"
    implementation "com.zaxxer:HikariCP"
    implementation "io.micrometer:micrometer-registry-prometheus-simpleclient"
    implementation "javax.cache:cache-api"
    implementation "org.apache.commons:commons-lang3"
    implementation "org.ehcache:ehcache::jakarta"
    implementation "org.hibernate.orm:hibernate-core"
    implementation "org.hibernate.orm:hibernate-jcache"
    implementation "org.hibernate.validator:hibernate-validator"
    implementation "org.postgresql:postgresql"
    implementation "io.seruco.encoding:base62:0.1.3"
    implementation "com.twilio.sdk:twilio:11.3.6"

    testImplementation(libs.archunit.junit5.api) {
        exclude group: 'org.slf4j', module: 'slf4j-api'
    }
    testImplementation "org.springframework.boot:spring-boot-starter-test"
    testImplementation "org.springframework.boot:spring-boot-test"
    testImplementation "org.springframework.security:spring-security-test"
    testImplementation "org.testcontainers:jdbc"
    testImplementation "org.testcontainers:junit-jupiter"
    testImplementation "org.testcontainers:postgresql"
    testImplementation "org.testcontainers:testcontainers"
    testRuntimeOnly(libs.archunit.junit5.engine) {
        exclude group: 'org.slf4j', module: 'slf4j-api'
    }
    annotationProcessor libs.mapstruct.processor
    annotationProcessor "org.springframework.boot:spring-boot-configuration-processor"
    annotationProcessor "org.glassfish.jaxb:jaxb-runtime"
    annotationProcessor "org.hibernate.orm:hibernate-jpamodelgen"
    developmentOnly "org.springframework.boot:spring-boot-docker-compose"
    // jhipster-needle-gradle-dependency - JHipster will add additional dependencies here
}
