diff options
Diffstat (limited to 'cps-rest')
-rwxr-xr-x | cps-rest/pom.xml | 41 | ||||
-rw-r--r-- | cps-rest/src/main/resources/application.yml | 5 |
2 files changed, 40 insertions, 6 deletions
diff --git a/cps-rest/pom.xml b/cps-rest/pom.xml index 128c56680b..49c3267dd9 100755 --- a/cps-rest/pom.xml +++ b/cps-rest/pom.xml @@ -1,6 +1,6 @@ <project xmlns="http://maven.apache.org/POM/4.0.0"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onap.cps</groupId>
@@ -98,10 +98,6 @@ <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
- <plugin>
- <groupId>com.google.cloud.tools</groupId>
- <artifactId>jib-maven-plugin</artifactId>
- </plugin>
<!-- Swagger code generation. -->
<plugin>
<groupId>io.swagger.codegen.v3</groupId>
@@ -109,4 +105,37 @@ </plugin>
</plugins>
</build>
+
+ <profiles>
+ <profile>
+ <id>docker</id>
+ <activation>
+ <activeByDefault>false</activeByDefault>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>com.google.cloud.tools</groupId>
+ <artifactId>jib-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <phase>package</phase>
+ <id>build</id>
+ <goals>
+ <goal>dockerBuild</goal>
+ </goals>
+ </execution>
+ <execution>
+ <phase>deploy</phase>
+ <id>buildAndPush</id>
+ <goals>
+ <goal>build</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
</project>
diff --git a/cps-rest/src/main/resources/application.yml b/cps-rest/src/main/resources/application.yml index e8af0bcfb2..80c6af6c68 100644 --- a/cps-rest/src/main/resources/application.yml +++ b/cps-rest/src/main/resources/application.yml @@ -22,6 +22,11 @@ spring: driverClassName: org.postgresql.Driver
initialization-mode: always
+ cache:
+ type: caffeine
+ cache-names: yangSchema
+ caffeine:
+ spec: maximumSize=10000,expireAfterAccess=10m
# Actuator
management:
endpoints:
|