|
1 | | -buildscript { |
2 | | - ext { |
3 | | - springBootVersion = '2.6.7' |
4 | | - wrapperVersion = '1.0.29.BUILD-SNAPSHOT' |
5 | | - shadowVersion = '5.1.0' |
6 | | - } |
7 | | - repositories { |
8 | | - mavenLocal() |
9 | | - jcenter() |
10 | | - mavenCentral() |
11 | | - maven { url "https://repo.spring.io/snapshot" } |
12 | | - maven { url "https://repo.spring.io/milestone" } |
13 | | - } |
14 | | - dependencies { |
15 | | - classpath "com.github.jengelman.gradle.plugins:shadow:${shadowVersion}" |
16 | | - classpath("org.springframework.boot.experimental:spring-boot-thin-gradle-plugin:${wrapperVersion}") |
17 | | - classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}") |
18 | | - classpath("io.spring.gradle:dependency-management-plugin:1.0.8.RELEASE") |
19 | | - } |
20 | | -} |
21 | | - |
22 | | -apply plugin: 'java' |
23 | | -apply plugin: 'maven-publish' |
24 | | -apply plugin: 'eclipse' |
25 | | -apply plugin: 'com.github.johnrengelman.shadow' |
26 | | -apply plugin: 'org.springframework.boot' |
27 | | -apply plugin: 'org.springframework.boot.experimental.thin-launcher' |
28 | | -apply plugin: 'io.spring.dependency-management' |
29 | | - |
30 | | -group = 'io.spring.sample' |
31 | | -version = '2.0.0.RELEASE' |
32 | | -sourceCompatibility = 1.8 |
33 | | -targetCompatibility = 1.8 |
| 1 | +/* |
| 2 | + * This file was generated by the Gradle 'init' task. |
| 3 | + */ |
34 | 4 |
|
35 | | -repositories { |
36 | | - mavenLocal() |
37 | | - mavenCentral() |
38 | | - maven { url "https://repo.spring.io/snapshot" } |
39 | | - maven { url "https://repo.spring.io/milestone" } |
| 5 | +plugins { |
| 6 | + id 'java-library' |
| 7 | + id 'maven-publish' |
40 | 8 | } |
41 | 9 |
|
42 | | -ext { |
43 | | - springCloudFunctionVersion = "3.2.4" |
44 | | - awsLambdaEventsVersion = "3.9.0" |
45 | | - awsLambdaCoreVersion = "1.1.0" |
46 | | -} |
47 | | -ext['reactor.version'] = "3.1.7.RELEASE" |
| 10 | +repositories { |
| 11 | + mavenLocal() |
| 12 | + maven { |
| 13 | + url = uri('https://repo.spring.io/snapshot') |
| 14 | + } |
48 | 15 |
|
49 | | -assemble.dependsOn = [shadowJar, thinJar] |
| 16 | + maven { |
| 17 | + url = uri('https://repo.spring.io/milestone') |
| 18 | + } |
50 | 19 |
|
51 | | -jar { |
52 | | - manifest { |
53 | | - attributes 'Main-Class': 'example.FunctionConfiguration' |
54 | | - } |
| 20 | + maven { |
| 21 | + url = uri('https://repo.maven.apache.org/maven2/') |
| 22 | + } |
55 | 23 | } |
56 | 24 |
|
57 | | -import com.github.jengelman.gradle.plugins.shadow.transformers.* |
58 | | - |
59 | | -shadowJar { |
60 | | - classifier = 'aws' |
61 | | - dependencies { |
62 | | - exclude( |
63 | | - dependency("org.springframework.cloud:spring-cloud-function-web:${springCloudFunctionVersion}")) |
64 | | - } |
65 | | - // Required for Spring |
66 | | - mergeServiceFiles() |
67 | | - append 'META-INF/spring.handlers' |
68 | | - append 'META-INF/spring.schemas' |
69 | | - append 'META-INF/spring.tooling' |
70 | | - transform(PropertiesFileTransformer) { |
71 | | - paths = ['META-INF/spring.factories'] |
72 | | - mergeStrategy = "append" |
73 | | - } |
| 25 | +dependencies { |
| 26 | + api 'org.springframework.cloud:spring-cloud-function-adapter-aws:4.0.3-SNAPSHOT' |
| 27 | + api 'com.amazonaws:aws-lambda-java-events:3.9.0' |
| 28 | + api 'org.springframework.boot:spring-boot-configuration-processor:3.0.5' |
| 29 | + testImplementation 'org.springframework.boot:spring-boot-starter-test:3.0.5' |
| 30 | + compileOnly 'com.amazonaws:aws-lambda-java-core:1.1.0' |
74 | 31 | } |
75 | 32 |
|
76 | | -configurations { |
77 | | - testCompile.extendsFrom(compileOnly) |
| 33 | +group = 'io.spring.sample' |
| 34 | +version = '4.0.0.RELEASE' |
| 35 | +description = 'function-sample-aws' |
| 36 | +java.sourceCompatibility = JavaVersion.VERSION_1_8 |
| 37 | + |
| 38 | +publishing { |
| 39 | + publications { |
| 40 | + maven(MavenPublication) { |
| 41 | + from(components.java) |
| 42 | + } |
| 43 | + } |
78 | 44 | } |
79 | 45 |
|
80 | | -dependencyManagement { |
81 | | - imports { |
82 | | - mavenBom "org.springframework.cloud:spring-cloud-function-dependencies:${springCloudFunctionVersion}" |
83 | | - } |
| 46 | +tasks.withType(JavaCompile) { |
| 47 | + options.encoding = 'UTF-8' |
84 | 48 | } |
85 | 49 |
|
86 | | -dependencies { |
87 | | - implementation("org.springframework.cloud:spring-cloud-function-adapter-aws") |
88 | | - implementation("org.springframework.cloud:spring-cloud-starter-function-webflux") |
89 | | - implementation("org.springframework.boot:spring-boot-configuration-processor") |
90 | | - compileOnly("com.amazonaws:aws-lambda-java-events:${awsLambdaEventsVersion}") |
91 | | - compileOnly("com.amazonaws:aws-lambda-java-core:${awsLambdaCoreVersion}") |
92 | | - testCompile('org.springframework.boot:spring-boot-starter-test') |
| 50 | +tasks.withType(Javadoc) { |
| 51 | + options.encoding = 'UTF-8' |
93 | 52 | } |
0 commit comments