-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
88 lines (73 loc) · 2.68 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
allprojects {
group 'com.acme'
version '1.0.0-SNAPSHOT'
}
subprojects {
buildscript {
ext {
set('spring-boot.version', '2.1.3.RELEASE')
set('lmax-disruptor.version', '3.4.2')
set('unexceptional.version', '1.0.0')
set('mapstruct.version', '1.3.0.Final')
}
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
}
}
apply plugin: 'java-library'
sourceCompatibility = 1.8
repositories {
mavenCentral()
jcenter()
}
configurations {
springBom
api.extendsFrom springBom
implementation.extendsFrom springBom
compileOnly.extendsFrom springBom
runtimeOnly.extendsFrom springBom
annotationProcessor.extendsFrom springBom
testApi.extendsFrom springBom
testImplementation.extendsFrom springBom
testCompileOnly.extendsFrom springBom
testRuntimeOnly.extendsFrom springBom
testAnnotationProcessor.extendsFrom springBom
}
dependencies {
springBom platform("org.springframework.boot:spring-boot-dependencies:${project.'spring-boot.version'}")
springBom platform('org.springframework.cloud:spring-cloud-dependencies:Greenwich.SR1')
// log4j2
implementation 'org.apache.logging.log4j:log4j-core'
implementation 'org.apache.logging.log4j:log4j-slf4j-impl'
implementation 'org.apache.logging.log4j:log4j-jcl'
implementation 'org.apache.logging.log4j:log4j-jul'
implementation "com.lmax:disruptor:${project.'lmax-disruptor.version'}"
// NOTE: Due to a bug as of now mapstruct needs to go before lombok
// https://github.com/mapstruct/mapstruct/issues/1581
// maspstruct
implementation "org.mapstruct:mapstruct:${project.'mapstruct.version'}"
annotationProcessor "org.mapstruct:mapstruct-processor:${project.'mapstruct.version'}"
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
// unexceptional for making sure code is not super polluted
implementation "io.earcam:io.earcam.unexceptional:${project.'unexceptional.version'}"
// junit
testImplementation 'org.junit.jupiter:junit-jupiter-api'
testImplementation 'org.junit.jupiter:junit-jupiter-engine'
testImplementation 'org.junit.jupiter:junit-jupiter-params'
testImplementation 'org.mockito:mockito-junit-jupiter'
configurations {
all {
// we need to exclude logging to avoid keeping both slf4j & log4j2 both in the same location
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-logging'
// `spring-boot-starter-test` is pulling older version of junit. Lets just ignore it
exclude group: 'junit', module: 'junit'
}
}
}
test {
useJUnitPlatform()
}
}