aboutsummaryrefslogtreecommitdiffstats
path: root/openapi
diff options
context:
space:
mode:
Diffstat (limited to 'openapi')
-rw-r--r--openapi/build.gradle19
-rw-r--r--openapi/client-portal-history/build.gradle54
-rw-r--r--openapi/client-portal-keycloak/build.gradle56
-rw-r--r--openapi/client-portal-prefs/build.gradle54
-rw-r--r--openapi/server/build.gradle16
5 files changed, 133 insertions, 66 deletions
diff --git a/openapi/build.gradle b/openapi/build.gradle
new file mode 100644
index 0000000..0b3e556
--- /dev/null
+++ b/openapi/build.gradle
@@ -0,0 +1,19 @@
+plugins {
+ id 'java'
+ id 'io.spring.dependency-management'
+}
+
+dependencies {
+ implementation project('server')
+ implementation project('client-portal-history')
+ implementation project('client-portal-keycloak')
+ implementation project('client-portal-prefs')
+}
+ext {
+ openapiVersion = '7.0.0-beta'
+}
+subprojects {
+ repositories {
+ mavenCentral()
+ }
+} \ No newline at end of file
diff --git a/openapi/client-portal-history/build.gradle b/openapi/client-portal-history/build.gradle
index e692169..4420d80 100644
--- a/openapi/client-portal-history/build.gradle
+++ b/openapi/client-portal-history/build.gradle
@@ -1,31 +1,17 @@
plugins {
+ id 'java'
+ id 'idea'
+ id 'org.springframework.boot'
+ id 'io.spring.dependency-management'
id 'org.openapi.generator'
}
dependencies {
- implementation "org.springframework.boot:spring-boot-starter-webflux"
- implementation "org.openapitools:openapi-generator:$openapiVersion"
+ implementation 'org.springframework.boot:spring-boot-starter-webflux'
+ implementation "org.openapitools:openapi-generator:$openapiVersion"
}
-compileJava {
- dependsOn = ['openApiGenerate_history']
-}
-
-sourceSets {
- main {
- java {
- srcDirs += file("$buildDir/openapi/src/main/java")
- }
- }
-}
-
-idea {
- module {
- generatedSourceDirs += file("$buildDir/openapi/src/main/java")
- }
-}
-
-tasks.register('openApiGenerate_history', org.openapitools.generator.gradle.plugin.tasks.GenerateTask) {
+openApiGenerate {
generatorName = "java"
library = "webclient"
inputSpec = "${project.projectDir}/src/portal_history_openapi.yaml"
@@ -46,4 +32,30 @@ tasks.register('openApiGenerate_history', org.openapitools.generator.gradle.plug
apiPackage = "org.onap.portalng.bff.openapi.client_portal_history.api"
modelPackage = "org.onap.portalng.bff.openapi.client_portal_history.model"
modelNameSuffix = "PortalHistoryDto"
+}
+
+compileJava {
+ dependsOn tasks.openApiGenerate
+}
+
+sourceSets {
+ main {
+ java {
+ srcDirs += file("$buildDir/openapi/src/main/java")
+ }
+ }
+}
+
+idea {
+ module {
+ generatedSourceDirs += file("$buildDir/openapi/src/main/java")
+ }
+}
+
+bootJar {
+ enabled = false
+}
+
+jar {
+ enabled = true
} \ No newline at end of file
diff --git a/openapi/client-portal-keycloak/build.gradle b/openapi/client-portal-keycloak/build.gradle
index 525fa18..d7984db 100644
--- a/openapi/client-portal-keycloak/build.gradle
+++ b/openapi/client-portal-keycloak/build.gradle
@@ -1,35 +1,21 @@
plugins {
+ id 'java'
+ id 'idea'
+ id 'org.springframework.boot'
+ id 'io.spring.dependency-management'
id 'org.openapi.generator'
}
dependencies {
- implementation "org.springframework.boot:spring-boot-starter-webflux"
- implementation "org.openapitools:openapi-generator:$openapiVersion"
+ implementation 'org.springframework.boot:spring-boot-starter-webflux'
+ implementation "org.openapitools:openapi-generator:$openapiVersion"
}
-compileJava {
- dependsOn = ['openApiGenerate_keycloak']
-}
-
-sourceSets {
- main {
- java {
- srcDirs += file("$buildDir/openapi/src/main/java")
- }
- }
-}
-
-idea {
- module {
- generatedSourceDirs += file("$buildDir/openapi/src/main/java")
- }
-}
-
-tasks.register('openApiGenerate_keycloak', org.openapitools.generator.gradle.plugin.tasks.GenerateTask) {
+openApiGenerate {
generatorName = "java"
library = "webclient"
inputSpec = "${project.projectDir}/src/portal_keycloak_openapi.yaml"
- outputDir = "${buildDir}/openapi"
+ outputDir = "${project.buildDir}/openapi"
configOptions = [
openApiNullable : "false",
dateLibrary : "java8",
@@ -46,4 +32,30 @@ tasks.register('openApiGenerate_keycloak', org.openapitools.generator.gradle.plu
apiPackage = "org.onap.portalng.bff.openapi.client_portal_keycloak.api"
modelPackage = "org.onap.portalng.bff.openapi.client_portal_keycloak.model"
modelNameSuffix = "KeycloakDto"
+}
+
+compileJava {
+ dependsOn tasks.openApiGenerate
+}
+
+sourceSets {
+ main {
+ java {
+ srcDirs += file("$buildDir/openapi/src/main/java")
+ }
+ }
+}
+
+idea {
+ module {
+ generatedSourceDirs += file("$buildDir/openapi/src/main/java")
+ }
+}
+
+bootJar {
+ enabled = false
+}
+
+jar {
+ enabled = true
} \ No newline at end of file
diff --git a/openapi/client-portal-prefs/build.gradle b/openapi/client-portal-prefs/build.gradle
index cb7122a..3229244 100644
--- a/openapi/client-portal-prefs/build.gradle
+++ b/openapi/client-portal-prefs/build.gradle
@@ -1,31 +1,17 @@
plugins {
+ id 'java'
+ id 'idea'
+ id 'org.springframework.boot'
+ id 'io.spring.dependency-management'
id 'org.openapi.generator'
}
dependencies {
- implementation "org.springframework.boot:spring-boot-starter-webflux"
- implementation "org.openapitools:openapi-generator:$openapiVersion"
+ implementation 'org.springframework.boot:spring-boot-starter-webflux'
+ implementation "org.openapitools:openapi-generator:$openapiVersion"
}
-compileJava {
- dependsOn = ['openApiGenerate_preferences']
-}
-
-sourceSets {
- main {
- java {
- srcDirs += file("$buildDir/openapi/src/main/java")
- }
- }
-}
-
-idea {
- module {
- generatedSourceDirs += file("$buildDir/openapi/src/main/java")
- }
-}
-
-tasks.register('openApiGenerate_preferences', org.openapitools.generator.gradle.plugin.tasks.GenerateTask) {
+openApiGenerate {
generatorName = "java"
library = "webclient"
inputSpec = "${project.projectDir}/src/portal_prefs_openapi.yaml"
@@ -46,4 +32,30 @@ tasks.register('openApiGenerate_preferences', org.openapitools.generator.gradle.
apiPackage = "org.onap.portalng.bff.openapi.client_portal_prefs.api"
modelPackage = "org.onap.portalng.bff.openapi.client_portal_prefs.model"
modelNameSuffix = "PortalPrefsDto"
+}
+
+compileJava {
+ dependsOn tasks.openApiGenerate
+}
+
+sourceSets {
+ main {
+ java {
+ srcDirs += file("$buildDir/openapi/src/main/java")
+ }
+ }
+}
+
+idea {
+ module {
+ generatedSourceDirs += file("$buildDir/openapi/src/main/java")
+ }
+}
+
+bootJar {
+ enabled = false
+}
+
+jar {
+ enabled = true
} \ No newline at end of file
diff --git a/openapi/server/build.gradle b/openapi/server/build.gradle
index 6cdc456..017a618 100644
--- a/openapi/server/build.gradle
+++ b/openapi/server/build.gradle
@@ -1,11 +1,15 @@
plugins {
+ id 'java'
+ id 'idea'
+ id 'org.springframework.boot'
+ id 'io.spring.dependency-management'
id 'org.openapi.generator'
}
dependencies {
- implementation "org.springframework.boot:spring-boot-starter-webflux"
+ implementation 'org.springframework.boot:spring-boot-starter-webflux'
implementation "org.openapitools:openapi-generator:$openapiVersion"
- implementation "org.webjars:redoc:$redocVersion"
+ // implementation 'jakarta.validation:jakarta.validation-api:3.0.2'
constraints {
implementation('io.swagger.core.v3:swagger-annotations:2.2.5') {
@@ -55,3 +59,11 @@ idea {
generatedSourceDirs += file("$buildDir/openapi/src/main/java")
}
}
+
+bootJar {
+ enabled = false
+}
+
+jar {
+ enabled = true
+} \ No newline at end of file