From 91ca2776da13be41f56e62b1fb68197f63c736d2 Mon Sep 17 00:00:00 2001 From: Tang Cheng Date: Mon, 16 Dec 2019 08:59:52 +0800 Subject: [PATCH] =?utf8?q?=E4=BC=98=E5=8C=96=20gradle?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- build.gradle | 144 +++++++++++++--- gradle/swnx-publish.gradle | 14 ++ oauth/build.gradle | 65 +++----- payapi-common/build.gradle | 46 ++---- payapi-sdk/build.gradle | 40 +---- payapi/build.gradle | 156 +++++++----------- .../supwisdom/dlpay/api/domain/TAccount.java | 2 +- .../dlpay/api/service/transaction_service.kt | 3 - ynrcc-agent/build.gradle | 30 +--- 9 files changed, 249 insertions(+), 251 deletions(-) create mode 100644 gradle/swnx-publish.gradle diff --git a/build.gradle b/build.gradle index a4cd5b1e..3bf4e381 100644 --- a/build.gradle +++ b/build.gradle @@ -1,40 +1,146 @@ plugins { id 'java' - id 'org.springframework.boot' version '2.1.6.RELEASE' - id 'io.spring.dependency-management' version '1.0.8.RELEASE' + id 'org.springframework.boot' version '2.1.6.RELEASE' apply false id 'org.jetbrains.kotlin.jvm' version '1.3.31' id 'org.jetbrains.kotlin.plugin.spring' version '1.3.31' + id 'org.jetbrains.kotlin.plugin.jpa' version '1.3.31' apply false id "com.palantir.git-version" version "0.12.0-rc2" - id 'com.palantir.docker' version '0.22.1' + id 'com.palantir.docker' version '0.22.1' apply false } +group = 'com.supwisdom' + allprojects { repositories { jcenter() mavenCentral() } -} + ext { + set('junit_jupiter_version', "5.5.2") + set("junit_platform_version", "1.5.2") + set("mockitoVersion", "3.1.0") + } -ext { - set('junit_jupiter_version', "5.5.2") - set("junit_platform_version", "1.5.2") - set("mockitoVersion", "3.1.0") + apply plugin: 'java' + apply plugin: 'io.spring.dependency-management' + + sourceCompatibility = JavaVersion.VERSION_1_8 + targetCompatibility = JavaVersion.VERSION_1_8 + + compileKotlin { + kotlinOptions { + freeCompilerArgs = ['-Xjsr305=strict'] + jvmTarget = jdkVersion + } + } + + compileTestKotlin { + kotlinOptions { + freeCompilerArgs = ['-Xjsr305=strict'] + jvmTarget = jdkVersion + } + } + + version = gitVersion() + ext { + details = versionDetails() + } } + subprojects { - apply plugin: 'java' - version = '1.0' + + ext { + set('springCloudVersion', "Hoxton.RELEASE") + } + dependencies { - testImplementation("org.junit.jupiter:junit-jupiter-api:${junit_jupiter_version}") - testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:${junit_jupiter_version}") - testRuntimeOnly("org.junit.platform:junit-platform-launcher:${junit_platform_version}") - testImplementation("io.mockk:mockk:1.9.3") - testImplementation("org.hamcrest:hamcrest:2.1") + ext { + slf4jVersion = '1.7.26' + beanutilsVersion = '1.9.3' + codecVersion = '1.13' + lang3Version = '3.9' + commonCodecVersion = '1.12' + lombokVersion = '1.18.8' + javaELVersion = '3.0.0' + shedlockVersion = '2.5.0' + jose4jVersion = '0.6.5' + jcabiManifestsVersion = '1.1' + kotlnLogVersion = '1.6.26' + slf4jVersion = '1.7.26' + gsonVersion = '2.8.5' + dbcpVersion = '1.4' + log4jVersion = '1.2.17' + alibabFastjsonVerison = '1.2.60' + beanutilsVersion = '1.9.3' + alipaySDKVersion = '3.7.110.ALL' + lombokVersion = '1.18.8' + resetAssuredVersion = '3.3.0' + hamcrestVersion = '2.1' + mockkVersion = '1.9.3' + commonNetVersion = '3.6' + kaptchaVersion = '2.3.2' + jerseyClientVersion = '1.19' + javaxWSRSVersion = '2.1.1' + dom4jVersion = '2.1.1' + springSocialVersion = '1.1.6.RELEASE' + springKafkaVersion = '2.2.8.RELEASE' + postgresVersion = '42.2.5' + } + implementation "org.jetbrains.kotlin:kotlin-reflect" + implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8" + + implementation "org.springframework.boot:spring-boot-starter-data-jpa" + implementation "org.springframework.boot:spring-boot-starter-data-redis" + implementation "org.springframework.boot:spring-boot-starter-validation" + + implementation "javax.validation:validation-api" + implementation "com.jcabi:jcabi-manifests:${jcabiManifestsVersion}" + implementation "org.slf4j:slf4j-parent:${slf4jVersion}" + implementation "org.slf4j:slf4j-api:${slf4jVersion}" + implementation "org.postgresql:postgresql:${postgresVersion}" + implementation "io.github.microutils:kotlin-logging:${kotlnLogVersion}" + implementation "org.slf4j:slf4j-parent:${slf4jVersion}" + implementation "com.google.code.gson:gson:${gsonVersion}" + implementation "commons-dbcp:commons-dbcp:${dbcpVersion}" + implementation "commons-codec:commons-codec:${commonCodecVersion}" + implementation "log4j:log4j:${log4jVersion}" + implementation "com.alibaba:fastjson:${alibabFastjsonVerison}" + implementation "com.fasterxml.jackson.module:jackson-module-kotlin" + + + annotationProcessor "org.springframework.boot:spring-boot-configuration-processor" + annotationProcessor "org.projectlombok:lombok:${lombokVersion}" + compileOnly "org.projectlombok:lombok:${lombokVersion}" + + // implementation "javax.el:javax.el-api:${javaELVersion}" + // implementation "javax.servlet:javax.servlet-api:4.0.1" +// testImplementation 'org.springframework:spring-test' +// testImplementation 'org.springframework.boot:spring-boot-test' +// implementation "javax.servlet:jstl:1.2" +// implementation "taglibs:standard:1.1.2" + testImplementation "org.springframework.boot:spring-boot-starter-test" + testImplementation "org.junit.jupiter:junit-jupiter-api:${junit_jupiter_version}" + testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:${junit_jupiter_version}" + testRuntimeOnly "org.junit.platform:junit-platform-launcher:${junit_platform_version}" + testImplementation "io.mockk:mockk:${mockkVersion}" + testImplementation "org.hamcrest:hamcrest:${hamcrestVersion}" + testImplementation "io.rest-assured:rest-assured:${resetAssuredVersion}" + testImplementation "io.rest-assured:spring-mock-mvc:${resetAssuredVersion}" + } + + test { + useJUnitPlatform() + testLogging { + events "passed", "skipped", "failed" + } } -} -bootJar { - enabled = false + dependencyManagement { + imports { + mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" + } + } } -group = 'com.supwisdom' \ No newline at end of file + diff --git a/gradle/swnx-publish.gradle b/gradle/swnx-publish.gradle new file mode 100644 index 00000000..13503863 --- /dev/null +++ b/gradle/swnx-publish.gradle @@ -0,0 +1,14 @@ +publishing { + repositories { + maven { + // change URLs to point to your repos, e.g. http://my.org/repo + def releasesRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/" + def snapshotsRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/snapshot/" + url = version.endsWith('dirty') ? snapshotsRepoUrl : releasesRepoUrl + credentials(PasswordCredentials) { + username = nxUser + password = nxPassword + } + } + } +} \ No newline at end of file diff --git a/oauth/build.gradle b/oauth/build.gradle index aeffb673..34967034 100644 --- a/oauth/build.gradle +++ b/oauth/build.gradle @@ -2,7 +2,7 @@ plugins { id 'java' id 'org.springframework.boot' id 'org.jetbrains.kotlin.jvm' - id 'org.jetbrains.kotlin.plugin.jpa' version '1.3.31' + id 'org.jetbrains.kotlin.plugin.jpa' id 'org.jetbrains.kotlin.plugin.spring' id "com.palantir.git-version" } @@ -10,11 +10,8 @@ plugins { apply plugin: 'java' apply plugin: 'io.spring.dependency-management' -def version = gitVersion() def details = versionDetails() -group = rootProject.group -version = '1' sourceCompatibility = jdkVersion def startClass = 'com.supwisdom.oauth.OAuthApplication' @@ -33,44 +30,28 @@ jar { dependencies { - implementation 'org.springframework.boot:spring-boot-starter-data-jpa' - implementation 'org.springframework.boot:spring-boot-starter-data-redis' - implementation 'org.springframework.boot:spring-boot-starter-web' - implementation 'org.springframework.boot:spring-boot-starter-security' - implementation 'org.springframework.boot:spring-boot-starter-cache' - implementation 'org.springframework.boot:spring-boot-autoconfigure' - implementation 'org.springframework.security:spring-security-oauth2-jose' - implementation 'org.springframework.security:spring-security-oauth2-client' - implementation 'org.springframework.security:spring-security-oauth2-jose' - implementation 'org.springframework.security.oauth.boot:spring-security-oauth2-autoconfigure:2.1.5.RELEASE' - implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' - implementation 'org.springframework.session:spring-session-data-redis' - implementation 'org.springframework.boot:spring-boot-starter-cache' - implementation 'org.springframework.social:spring-social-web:1.1.6.RELEASE' - implementation 'org.jetbrains.kotlin:kotlin-reflect' - implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8' - implementation 'commons-codec:commons-codec:1.12' - implementation 'org.apache.commons:commons-lang3:3.9' - implementation 'net.javacrumbs.shedlock:shedlock-spring:2.5.0' - implementation 'net.javacrumbs.shedlock:shedlock-provider-redis-spring:2.5.0' - - implementation 'org.thymeleaf.extras:thymeleaf-extras-springsecurity5' - - implementation 'org.postgresql:postgresql:42.2.5' - implementation 'com.fasterxml.jackson.module:jackson-module-kotlin' - implementation 'com.jcabi:jcabi-manifests:1.1' - implementation 'org.bitbucket.b_c:jose4j:0.6.5' - implementation 'io.github.microutils:kotlin-logging:1.6.26' - implementation 'org.slf4j:slf4j-parent:1.7.26' - - implementation 'commons-dbcp:commons-dbcp:1.4' - - implementation project(':payapi-common') - - testImplementation 'org.springframework.boot:spring-boot-starter-test' - testImplementation 'io.rest-assured:rest-assured:3.3.0' - testImplementation 'io.rest-assured:spring-mock-mvc:3.3.0' - testImplementation 'org.hamcrest:hamcrest:2.1' + implementation project(":payapi-common") + + implementation "org.springframework.boot:spring-boot-starter-data-jpa" + implementation "org.springframework.boot:spring-boot-starter-data-redis" + implementation "org.springframework.boot:spring-boot-starter-web" + implementation "org.springframework.boot:spring-boot-starter-security" + implementation "org.springframework.boot:spring-boot-starter-cache" + implementation "org.springframework.boot:spring-boot-autoconfigure" + implementation "org.springframework.security:spring-security-oauth2-jose" + implementation "org.springframework.security:spring-security-oauth2-client" + implementation "org.springframework.security:spring-security-oauth2-jose" + implementation "org.springframework.security.oauth.boot:spring-security-oauth2-autoconfigure" + implementation "org.springframework.boot:spring-boot-starter-thymeleaf" + implementation "org.springframework.session:spring-session-data-redis" + implementation "org.springframework.boot:spring-boot-starter-cache" + + implementation "org.thymeleaf.extras:thymeleaf-extras-springsecurity5" + implementation "org.springframework.social:spring-social-web:${springSocialVersion}" + implementation "net.javacrumbs.shedlock:shedlock-spring:${shedlockVersion}" + implementation "net.javacrumbs.shedlock:shedlock-provider-redis-spring:${shedlockVersion}" + implementation "org.bitbucket.b_c:jose4j:${jose4jVersion}" + implementation "org.apache.commons:commons-lang3:${lang3Version}" } diff --git a/payapi-common/build.gradle b/payapi-common/build.gradle index 106d0ad3..7ae26c0c 100644 --- a/payapi-common/build.gradle +++ b/payapi-common/build.gradle @@ -1,11 +1,14 @@ plugins { - id 'java-library' - id 'maven-publish' - id "com.palantir.git-version" + id "java-library" + id "maven-publish" + id "org.springframework.boot" } -group = rootProject.group -version = gitVersion() +bootJar { + enabled = false +} + +apply from: rootProject.file('gradle/swnx-publish.gradle') publishing { publications { @@ -16,36 +19,13 @@ publishing { from components.java } } - repositories { - maven { - // change URLs to point to your repos, e.g. http://my.org/repo - def releasesRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/" - def snapshotsRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/snapshot/" - url = version.endsWith('dirty') ? snapshotsRepoUrl : releasesRepoUrl - credentials(PasswordCredentials) { - username = nxUser - password = nxPassword - } - } - } } dependencies { - implementation 'org.slf4j:slf4j-parent:1.7.26' - implementation 'org.slf4j:slf4j-api:1.7.26' - implementation 'javax.validation:validation-api:2.0.1.Final' - implementation 'javax.servlet:javax.servlet-api:4.0.1' - implementation 'commons-beanutils:commons-beanutils:1.9.3' - implementation 'commons-codec:commons-codec:1.13' - implementation('org.springframework.boot:spring-boot-starter-validation:2.1.6.RELEASE') - - implementation 'org.hibernate:hibernate-validator:6.0.2.Final' - compile 'javax.el:javax.el-api:3.0.0' - compile 'org.glassfish.web:javax.el:2.2.6' - - compileOnly 'org.projectlombok:lombok:1.18.8' - annotationProcessor 'org.projectlombok:lombok:1.18.8' - - implementation 'org.apache.commons:commons-lang3:3.9' + implementation "commons-beanutils:commons-beanutils:${beanutilsVersion}" + implementation "commons-codec:commons-codec:${codecVersion}" + implementation "org.apache.commons:commons-lang3:${lang3Version}" + compileOnly "org.projectlombok:lombok:${lombokVersion}" + annotationProcessor "org.projectlombok:lombok:${lombokVersion}" } \ No newline at end of file diff --git a/payapi-sdk/build.gradle b/payapi-sdk/build.gradle index 6151e730..f76dc3a8 100644 --- a/payapi-sdk/build.gradle +++ b/payapi-sdk/build.gradle @@ -5,13 +5,13 @@ plugins { id "com.palantir.git-version" } - apply plugin: 'io.spring.dependency-management' -group = rootProject.group - def sdkVersion = gitVersion() + +apply from: rootProject.file('gradle/swnx-publish.gradle') + publishing { publications { mavenJava(MavenPublication) { @@ -21,18 +21,6 @@ publishing { from components.java } } - repositories { - maven { - // change URLs to point to your repos, e.g. http://my.org/repo - def releasesRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/" - def snapshotsRepoUrl = "http://ykt-nx.supwisdom.com/repository/ecard-repo/snapshot/" - url = version.endsWith('dirty') ? snapshotsRepoUrl : releasesRepoUrl - credentials(PasswordCredentials) { - username = nxUser - password = nxPassword - } - } - } } bootJar { @@ -40,26 +28,10 @@ bootJar { } dependencies { - implementation 'org.springframework.boot:spring-boot-starter-data-jpa' - implementation 'org.springframework.boot:spring-boot-starter-data-redis' - - implementation project(':payapi-common') - - implementation 'org.springframework.cloud:spring-cloud-dependencies:Finchley.SR3' - implementation 'org.springframework.cloud:spring-cloud-starter-openfeign:2.1.2.RELEASE' - - implementation 'javax.servlet:javax.servlet-api:4.0.1' - compileOnly 'org.projectlombok:lombok:1.18.8' - annotationProcessor 'org.projectlombok:lombok:1.18.8' - compile 'com.github.mwiede:feign-validation:1.0' + implementation project(":payapi-common") - testImplementation 'org.springframework:spring-test' - testImplementation 'org.springframework.boot:spring-boot-test' - testImplementation 'junit:junit:4.12' - testAnnotationProcessor 'org.projectlombok:lombok:1.18.8' - testCompileOnly 'org.projectlombok:lombok:1.18.8' - testImplementation 'org.hamcrest:hamcrest:2.1' - testImplementation project(':payapi-common') + implementation "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" + implementation "org.springframework.cloud:spring-cloud-starter-openfeign" } diff --git a/payapi/build.gradle b/payapi/build.gradle index 76f80e3c..2a68a1d4 100644 --- a/payapi/build.gradle +++ b/payapi/build.gradle @@ -1,51 +1,55 @@ import java.text.SimpleDateFormat plugins { - id 'java' - id 'org.springframework.boot' - id 'io.spring.dependency-management' - id 'org.jetbrains.kotlin.jvm' - id 'org.jetbrains.kotlin.plugin.jpa' version '1.3.31' - id 'org.jetbrains.kotlin.plugin.spring' - id "com.palantir.git-version" - id 'com.palantir.docker' + id "java" + id "org.springframework.boot" + id "org.jetbrains.kotlin.jvm" + id "org.jetbrains.kotlin.plugin.jpa" + id "org.jetbrains.kotlin.plugin.spring" + id "com.palantir.docker" } -payapiVersion = gitVersion() -def details = versionDetails() +payapiVersion = version -group = rootProject.group -version = '1' -sourceCompatibility = jdkVersion -def payapiStartClass = 'com.supwisdom.dlpay.PayApiApplicationKt' +def payapiStartClass = "com.supwisdom.dlpay.PayApiApplicationKt" println("Build version: $payapiVersion") bootJar { mainClassName = payapiStartClass manifest { - attributes('Payapi-Version': payapiVersion, - 'Payapi-Buildtime': new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ").format(new Date())) + attributes("Payapi-Version": payapiVersion, + "Payapi-Buildtime": new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ssZ").format(new Date())) } } jar { - baseName = 'payapi' + baseName = "payapi" } -ext { - set('springCloudVersion', "Greenwich.SR2") +compileKotlin { + kotlinOptions { + freeCompilerArgs = ["-Xjsr305=strict"] + jvmTarget = jdkVersion + } +} + +compileTestKotlin { + kotlinOptions { + freeCompilerArgs = ["-Xjsr305=strict"] + jvmTarget = jdkVersion + } } docker { def imageVersion if (details.gitHashFull.startsWith(details.lastTag) || !details.isCleanTag) { - imageVersion = 'dev' + imageVersion = "dev" } else { imageVersion = details.lastTag } println("Docker image tag : " + imageVersion) - name 'harbor.supwisdom.com/dali/payapi:' + imageVersion + name "harbor.supwisdom.com/dali/payapi:" + imageVersion println(jar.archivePath) files jar.archivePath } @@ -53,88 +57,44 @@ docker { docker.dependsOn(jar) dependencies { - implementation 'org.springframework.boot:spring-boot-starter-data-jpa' - implementation 'org.springframework.boot:spring-boot-starter-data-redis' - implementation 'org.springframework.boot:spring-boot-starter-web' - implementation 'org.springframework.boot:spring-boot-starter-security' - implementation 'org.springframework.boot:spring-boot-starter-cache' - implementation 'org.springframework.boot:spring-boot-autoconfigure' - implementation 'org.springframework.security:spring-security-oauth2-jose' - implementation 'org.springframework.security:spring-security-oauth2-client' - implementation 'org.springframework.security:spring-security-oauth2-jose' - implementation 'org.springframework.security.oauth.boot:spring-security-oauth2-autoconfigure:2.1.5.RELEASE' - implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' - implementation 'org.springframework.session:spring-session-data-redis' - implementation 'org.springframework.boot:spring-boot-starter-cache' - implementation 'org.springframework.kafka:spring-kafka' - implementation 'org.springframework.social:spring-social-web:1.1.6.RELEASE' - implementation 'org.springframework.kafka:spring-kafka:2.2.8.RELEASE' - implementation 'org.jetbrains.kotlin:kotlin-reflect' - implementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8' - implementation 'commons-codec:commons-codec:1.12' - implementation 'org.apache.commons:commons-lang3:3.9' - implementation 'net.javacrumbs.shedlock:shedlock-spring:2.5.0' - implementation 'net.javacrumbs.shedlock:shedlock-provider-redis-spring:2.5.0' - - implementation 'org.springframework.cloud:spring-cloud-starter' - implementation 'org.springframework.cloud:spring-cloud-starter-consul-discovery' - implementation 'org.springframework.cloud:spring-cloud-starter-netflix-hystrix' - implementation 'org.springframework.cloud:spring-cloud-starter-netflix-hystrix-dashboard' - - implementation 'org.thymeleaf.extras:thymeleaf-extras-springsecurity5' + implementation project(":payapi-common") + + implementation "org.springframework.boot:spring-boot-starter-web" + implementation "org.springframework.boot:spring-boot-starter-security" + implementation "org.springframework.boot:spring-boot-starter-cache" + implementation "org.springframework.boot:spring-boot-autoconfigure" + implementation "org.springframework.security:spring-security-oauth2-jose" + implementation "org.springframework.security:spring-security-oauth2-client" + implementation "org.springframework.security:spring-security-oauth2-jose" + implementation "org.springframework.security.oauth.boot:spring-security-oauth2-autoconfigure:2.1.5.RELEASE" + implementation "org.springframework.boot:spring-boot-starter-thymeleaf" + implementation "org.springframework.session:spring-session-data-redis" + implementation "org.springframework.boot:spring-boot-starter-cache" + implementation "org.springframework.kafka:spring-kafka" + implementation "org.springframework.social:spring-social-web:${springSocialVersion}" + implementation "org.springframework.kafka:spring-kafka:${springKafkaVersion}" + + implementation "org.springframework.cloud:spring-cloud-starter" + implementation "org.springframework.cloud:spring-cloud-starter-consul-discovery" + implementation "org.springframework.cloud:spring-cloud-starter-netflix-hystrix" + implementation "org.springframework.cloud:spring-cloud-starter-netflix-hystrix-dashboard" + runtime("org.springframework.boot:spring-boot-devtools") - implementation 'org.postgresql:postgresql:42.2.5' - implementation 'com.fasterxml.jackson.module:jackson-module-kotlin' - implementation 'com.jcabi:jcabi-manifests:1.1' - implementation 'org.bitbucket.b_c:jose4j:0.6.5' - implementation 'io.github.microutils:kotlin-logging:1.6.26' - implementation 'org.slf4j:slf4j-parent:1.7.26' - implementation 'com.github.penggle:kaptcha:2.3.2' - implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.5' - implementation group: 'com.sun.jersey', name: 'jersey-client', version: '1.19' - implementation group: 'javax.servlet', name: 'jstl', version: '1.2' - implementation group: 'taglibs', name: 'standard', version: '1.1.2' - implementation group: 'commons-codec', name: 'commons-codec', version: '1.13' - implementation files('libs/masmgc.sdk.sms-0.0.1-SNAPSHOT.jar') -// implementation files('libs/ojdbc6.jar') - implementation 'commons-dbcp:commons-dbcp:1.4' - implementation 'commons-beanutils:commons-beanutils:1.9.3' - - implementation 'log4j:log4j:1.2.17' - implementation 'com.alibaba:fastjson:1.2.60' - - implementation project(':payapi-common') - /*支付宝SDK*/ - implementation group: 'com.alipay.sdk', name: 'alipay-sdk-java', version: '3.7.110.ALL' + implementation "org.thymeleaf.extras:thymeleaf-extras-springsecurity5" - annotationProcessor "org.springframework.boot:spring-boot-configuration-processor" - annotationProcessor 'org.projectlombok:lombok:1.18.8' - compileOnly 'org.projectlombok:lombok:1.18.8' + implementation "org.apache.commons:commons-lang3:${lang3Version}" + implementation "net.javacrumbs.shedlock:shedlock-spring:${shedlockVersion}" + implementation "net.javacrumbs.shedlock:shedlock-provider-redis-spring:${shedlockVersion}" -// providedRuntime 'org.springframework.boot:spring-boot-starter-tomcat' - testImplementation 'org.springframework.boot:spring-boot-starter-test' - testImplementation 'io.rest-assured:rest-assured:3.3.0' - testImplementation 'io.rest-assured:spring-mock-mvc:3.3.0' - testImplementation 'org.hamcrest:hamcrest:2.1' -} + implementation "org.bitbucket.b_c:jose4j:${jose4jVersion}" + implementation files("libs/masmgc.sdk.sms-0.0.1-SNAPSHOT.jar") + implementation "commons-beanutils:commons-beanutils:${beanutilsVersion}" + /*支付宝SDK*/ + implementation "com.alipay.sdk:alipay-sdk-java:${alipaySDKVersion}" -dependencyManagement { - imports { - mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" - } -} + implementation "com.github.penggle:kaptcha:${kaptchaVersion}" + implementation "com.sun.jersey:jersey-client:${jerseyClientVersion}" -compileKotlin { - kotlinOptions { - freeCompilerArgs = ['-Xjsr305=strict'] - jvmTarget = jdkVersion - } } -compileTestKotlin { - kotlinOptions { - freeCompilerArgs = ['-Xjsr305=strict'] - jvmTarget = jdkVersion - } -} diff --git a/payapi/src/main/java/com/supwisdom/dlpay/api/domain/TAccount.java b/payapi/src/main/java/com/supwisdom/dlpay/api/domain/TAccount.java index 56e0caed..7b04f82f 100644 --- a/payapi/src/main/java/com/supwisdom/dlpay/api/domain/TAccount.java +++ b/payapi/src/main/java/com/supwisdom/dlpay/api/domain/TAccount.java @@ -18,7 +18,7 @@ import java.sql.Timestamp; public class TAccount implements Serializable { @Id @GenericGenerator(name = "idGenerator", strategy = "uuid") - @GeneratedValue(generator = "idGenerator") + @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "idGenerator") @Column(name = "ACCNO", nullable = false, length = 32) private String accno; //账号 diff --git a/payapi/src/main/kotlin/com/supwisdom/dlpay/api/service/transaction_service.kt b/payapi/src/main/kotlin/com/supwisdom/dlpay/api/service/transaction_service.kt index e7589f18..2e0ff912 100644 --- a/payapi/src/main/kotlin/com/supwisdom/dlpay/api/service/transaction_service.kt +++ b/payapi/src/main/kotlin/com/supwisdom/dlpay/api/service/transaction_service.kt @@ -67,9 +67,6 @@ class TransactionServiceProxy { @Autowired private lateinit var shopAccBalanceAsyncTask: ShopAccBalanceAsyncTask - @Autowired - private lateinit var kafkaSendMsgService: KafkaSendMsgService - @Autowired private lateinit var transactionMainDao: TransactionMainDao diff --git a/ynrcc-agent/build.gradle b/ynrcc-agent/build.gradle index 4c222f6f..2e612c19 100644 --- a/ynrcc-agent/build.gradle +++ b/ynrcc-agent/build.gradle @@ -8,11 +8,9 @@ plugins { apply plugin: 'java' apply plugin: 'io.spring.dependency-management' -def ynrccVersion = gitVersion() +def ynrccVersion = version def details = versionDetails() -group = rootProject.group -version = '1' sourceCompatibility = jdkVersion def ynrccStartClass = 'com.supwisdom.agent.YnrccAgentApplication' @@ -46,25 +44,15 @@ docker.dependsOn(jar) dependencies { - implementation 'org.springframework.boot:spring-boot-starter-web' - implementation 'org.springframework.boot:spring-boot-autoconfigure' - implementation 'commons-codec:commons-codec:1.12' - implementation 'com.jcabi:jcabi-manifests:1.1' - implementation 'org.slf4j:slf4j-parent:1.7.26' - implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.5' - implementation group: 'com.sun.jersey', name: 'jersey-client', version: '1.19' - implementation group: 'javax.servlet', name: 'jstl', version: '1.2' - implementation group: 'taglibs', name: 'standard', version: '1.1.2' - implementation group: 'commons-codec', name: 'commons-codec', version: '1.6' - implementation 'org.dom4j:dom4j:2.1.1' - implementation 'commons-beanutils:commons-beanutils:1.9.3' - implementation 'commons-net:commons-net:3.6' + implementation project(":payapi-common") - implementation project(':payapi-common') + implementation "org.springframework.boot:spring-boot-starter-web" + implementation "org.springframework.boot:spring-boot-autoconfigure" + implementation "javax.ws.rs:javax.ws.rs-api:${javaxWSRSVersion}" + + implementation "org.dom4j:dom4j:${dom4jVersion}" + implementation "commons-beanutils:commons-beanutils:${beanutilsVersion}" + implementation "commons-net:commons-net:${commonNetVersion}" - testImplementation 'org.springframework.boot:spring-boot-starter-test' - testImplementation 'io.rest-assured:rest-assured:3.3.0' - testImplementation 'io.rest-assured:spring-mock-mvc:3.3.0' - testImplementation 'org.hamcrest:hamcrest:2.1' } -- 2.17.1