From: kaixiang.xia Date: Wed, 8 Jul 2020 06:46:17 +0000 (+0800) Subject: Merge tag '1.0.16' into develop X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=051c7d76f36abda1cb916e7ab5b8f06737e73eaa;p=epayment%2Ffood_payapi.git Merge tag '1.0.16' into develop 合并1.0.16 --- 051c7d76f36abda1cb916e7ab5b8f06737e73eaa diff --cc build.gradle index fe5a7de6,2acc8810..296f7154 --- a/build.gradle +++ b/build.gradle @@@ -15,132 -13,19 +15,135 @@@ allprojects jcenter() mavenCentral() } - + 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 { - version = '1.0' -} -bootJar { - enabled = false + ext { + set('springCloudVersion', "Hoxton.RELEASE") + } + + dependencies { + 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.3.4.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" + 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 "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" + } + } + + dependencyManagement { + imports { + mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}" + } + } } + tasks.withType(JavaCompile) { + options.encoding = "UTF-8" + } -group = 'com.supwisdom' diff --cc oauth/build.gradle index 34967034,232445fb..28543623 --- a/oauth/build.gradle +++ b/oauth/build.gradle @@@ -28,30 -31,51 +28,35 @@@ jar baseName = 'oauth' } + tasks.withType(JavaCompile) { + options.encoding = "UTF-8" + } + + 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 --cc payapi-common/build.gradle index 7ae26c0c,c257e6a0..09ae6d4e --- a/payapi-common/build.gradle +++ b/payapi-common/build.gradle @@@ -22,10 -19,39 +22,16 @@@ publishing } 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 'com.fasterxml.jackson.core:jackson-annotations:2.10.1' - 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 "commons-beanutils:commons-beanutils:${beanutilsVersion}" + implementation "commons-codec:commons-codec:${codecVersion}" + implementation "org.apache.commons:commons-lang3:${lang3Version}" - implementation 'org.apache.commons:commons-lang3:3.9' + compileOnly "org.projectlombok:lombok:${lombokVersion}" + annotationProcessor "org.projectlombok:lombok:${lombokVersion}" - } + + testImplementation 'junit:junit:4.12' + } + + tasks.withType(JavaCompile) { + options.encoding = "UTF-8" + } diff --cc payapi/build.gradle index 29383172,5d8338c9..364856ca --- a/payapi/build.gradle +++ b/payapi/build.gradle @@@ -1,17 -1,28 +1,18 @@@ 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 = version -tasks.withType(JavaCompile) { - options.encoding = "UTF-8" -} - - + payapiVersion = gitVersion() + def details = versionDetails() -group = rootProject.group -version = '1' -sourceCompatibility = jdkVersion -def payapiStartClass = 'com.supwisdom.dlpay.PayApiApplicationKt' +def payapiStartClass = "com.supwisdom.dlpay.PayApiApplicationKt" println("Build version: $payapiVersion") @@@ -87,23 -99,48 +88,27 @@@ dependencies 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 'com.eatthepath:java-otp:0.1.0' implementation project(':payapi-common') - /*支付宝SDK*/ - implementation group: 'com.alipay.sdk', name: 'alipay-sdk-java', version: '3.7.110.ALL' - 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 - } ++tasks.withType(JavaCompile) { ++ options.encoding = "UTF-8" + } ++