This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To build locally: | |
# docker build -t xm-database-postgress . | |
FROM eclipse-temurin:11 as JDK | |
# use the same version of flyway in build.gradle | |
FROM flyway/flyway:6.2.4 as flyway | |
# Replace with your base PG image here: | |
FROM XXXXXourBasePostgresImageXXXXXXXX:14.3 as database | |
ENV JAVA_HOME=/opt/jdk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import groovy.sql.Sql | |
task dropDatabase { | |
doLast { | |
Class.forName("org.postgresql.Driver") | |
def sql = groovy.sql.Sql.newInstance( | |
"jdbc:postgresql://localhost:5432/", | |
${DBA_USER}, | |
${DBA_PASSWORD}, | |
"org.postgresql.Driver" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gradle.build | |
``` | |
repositories { | |
maven { url "file:libs" } | |
maven { url "${nexus}" } | |
} | |
implementation "com.xmatters.springboot.common:exceptions:1.246.0", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task exportApiServiceParametersJar(type : Jar) { | |
from { sourceSets.main.output.classesDirs } { | |
include "com/foo/api/service/parameters/**" | |
} | |
dependsOn compileJava | |
} | |
task exportApiPagingJar(type : Jar) { | |
from { sourceSets.main.output.classesDirs } { | |
include "com/foo/api/paging/**" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Value("#{${deny.shift}}") Map<UUID, Set<UUID>> denyShiftsList | |
deny.shift={'044057a6-1380-4ec8-b0f0-25cf638927bd': {'542e3319-1186-446c-9c1a-b1892bcc5243'} } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.naxsoft.database; | |
import org.hibernate.Query; | |
import org.hibernate.ScrollMode; | |
import org.hibernate.ScrollableResults; | |
import org.hibernate.StatelessSession; | |
import rx.Observable; | |
/** | |
* Copyright NAXSoft 2015 |