FINERACT-1694: Making Avro mapping to fail at compile time for unmapped properties

This commit is contained in:
Arnold Galovics
2022-09-06 13:05:22 +02:00
committed by Arnold Gálovics
parent 3f1743a3d4
commit 4f312f33f6
157 changed files with 931 additions and 2919 deletions
+18 -2
View File
@@ -45,7 +45,7 @@ task buildJavaSdk(type: org.openapitools.generator.gradle.plugin.tasks.GenerateT
validateSpec = false
skipValidateSpec = true
inputSpec = "file:///$swaggerFile"
outputDir = "$buildDir/generated/java".toString()
outputDir = "$buildDir/generated/temp-java".toString()
templateDir = "$projectDir/src/main/resources/templates/java"
groupId = 'org.apache.fineract'
apiPackage = 'org.apache.fineract.client.services'
@@ -110,8 +110,24 @@ task buildAsciidoc(type: org.openapitools.generator.gradle.plugin.tasks.Generate
dependsOn(':fineract-provider:resolve')
}
task cleanupJodaImports() {
// This is a temporary step to get rid of joda imports in the generated code
// At this point it's unknown why it's even generated, probably it's a bug in the generator
doLast {
copy {
from "$buildDir/generated/temp-java".toString()
into "$buildDir/generated/java".toString()
filter { line ->
line.replaceAll("import org\\.joda\\.time\\.\\*;", "")
}
}
}
dependsOn("buildJavaSdk")
}
// TODO: @vidakovic we could provide even more client libs in different languages (Go, Ruby, Swift etc.)
compileJava.dependsOn(buildJavaSdk, buildTypescriptAngularSdk, buildAsciidoc, licenseFormatMain, spotlessMiscApply)
compileJava.dependsOn(buildJavaSdk, buildTypescriptAngularSdk, buildAsciidoc, cleanupJodaImports, licenseFormatMain, spotlessMiscApply)
java {
// keep this at Java 8, not 17; see https://issues.apache.org/jira/browse/FINERACT-1214