Skip to content
This repository was archived by the owner on Mar 13, 2021. It is now read-only.

Commit 1551c89

Browse files
trisbergdsyer
authored andcommitted
Simplifying the uppercase sample
- adding the .mvn wrapper to each sample - making the POMs a bit more uniform
1 parent d32c2c2 commit 1551c89

File tree

13 files changed

+52
-120
lines changed

13 files changed

+52
-120
lines changed

samples/greeter/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/*
22
!.gitignore
33
!src
4+
!.mvn
45
!mvnw*
56
!pom.xml
67
!README.*
46.5 KB
Binary file not shown.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.5.3/apache-maven-3.5.3-bin.zip

samples/greeter/pom.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,8 @@
66
<version>1.0.0</version>
77
<packaging>jar</packaging>
88

9+
<name>greeter</name>
10+
<description>Sample project for riff using String</description>
11+
<url>https://github.com/projectriff/java-function-invoker</url>
12+
913
</project>

samples/uppercase/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/*
22
!.gitignore
33
!src
4+
!.mvn
45
!mvnw*
56
!pom.xml
67
!README.*
46.5 KB
Binary file not shown.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.5.3/apache-maven-3.5.3-bin.zip

samples/uppercase/README.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,14 @@ N.B. this sample uses Spring (without really needing to, but just to show how it
2626
=== create the function and its input topic
2727

2828
```
29-
riff create java --input words --handler 'uppercase&main=functions.Application'
29+
riff create java --handler 'uppercase&main=functions.UppercaseApplication'
3030
```
3131

3232
=== publish a message and wait for a reply
3333

3434
In a terminal window:
3535
```
36-
riff publish --input words --data hello --reply
36+
riff publish --data hello --reply
3737
```
3838

3939
=== delete the function and its input topic

samples/uppercase/pom.xml

Lines changed: 21 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
12
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2-
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
3+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
34
<modelVersion>4.0.0</modelVersion>
45

56
<groupId>io.projectriff.samples</groupId>
@@ -8,34 +9,30 @@
89
<packaging>jar</packaging>
910

1011
<name>uppercase</name>
11-
<url>http://maven.apache.org</url>
12+
<description>Sample project for riff using Spring Boot</description>
13+
<url>https://github.com/projectriff/java-function-invoker</url>
1214

1315
<parent>
1416
<groupId>org.springframework.boot</groupId>
1517
<artifactId>spring-boot-starter-parent</artifactId>
1618
<version>2.0.1.RELEASE</version>
17-
<relativePath/>
19+
<relativePath/> <!-- lookup parent from repository -->
1820
</parent>
1921

2022
<properties>
2123
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
22-
<maven.compiler.source>1.8</maven.compiler.source>
23-
<maven.compiler.target>1.8</maven.compiler.target>
24-
<spring-cloud-function.version>1.0.0.BUILD-SNAPSHOT</spring-cloud-function.version>
24+
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
25+
<java.version>1.8</java.version>
2526
<reactor.version>3.1.2.RELEASE</reactor.version>
26-
<maven-surefire-plugin.version>2.19.1</maven-surefire-plugin.version>
27+
<spring-cloud-function.version>1.0.0.M6</spring-cloud-function.version>
2728
</properties>
2829

2930
<dependencies>
30-
<dependency>
31+
<dependency>
3132
<groupId>org.springframework.cloud</groupId>
3233
<artifactId>spring-cloud-starter-function-web</artifactId>
3334
</dependency>
34-
<dependency>
35-
<groupId>org.springframework.boot</groupId>
36-
<artifactId>spring-boot-configuration-processor</artifactId>
37-
<optional>true</optional>
38-
</dependency>
35+
3936
<dependency>
4037
<groupId>org.springframework.boot</groupId>
4138
<artifactId>spring-boot-starter-test</artifactId>
@@ -55,78 +52,24 @@
5552
</dependencies>
5653
</dependencyManagement>
5754

58-
<build>
59-
<plugins>
60-
<plugin>
61-
<groupId>org.apache.maven.plugins</groupId>
62-
<artifactId>maven-deploy-plugin</artifactId>
63-
<configuration>
64-
<skip>true</skip>
65-
</configuration>
66-
</plugin>
67-
<plugin>
68-
<groupId>org.springframework.boot</groupId>
69-
<artifactId>spring-boot-maven-plugin</artifactId>
70-
</plugin>
71-
</plugins>
72-
</build>
73-
7455
<repositories>
75-
<repository>
76-
<id>spring-snapshots</id>
77-
<name>Spring Snapshots</name>
78-
<url>https://repo.spring.io/libs-snapshot-local</url>
79-
<snapshots>
80-
<enabled>true</enabled>
81-
</snapshots>
82-
<releases>
83-
<enabled>false</enabled>
84-
</releases>
85-
</repository>
8656
<repository>
8757
<id>spring-milestones</id>
8858
<name>Spring Milestones</name>
89-
<url>https://repo.spring.io/libs-milestone-local</url>
90-
<snapshots>
91-
<enabled>false</enabled>
92-
</snapshots>
93-
</repository>
94-
<repository>
95-
<id>spring-releases</id>
96-
<name>Spring Releases</name>
97-
<url>https://repo.spring.io/release</url>
59+
<url>https://repo.spring.io/libs-milestone</url>
9860
<snapshots>
9961
<enabled>false</enabled>
10062
</snapshots>
10163
</repository>
10264
</repositories>
103-
<pluginRepositories>
104-
<pluginRepository>
105-
<id>spring-snapshots</id>
106-
<name>Spring Snapshots</name>
107-
<url>https://repo.spring.io/libs-snapshot-local</url>
108-
<snapshots>
109-
<enabled>true</enabled>
110-
</snapshots>
111-
<releases>
112-
<enabled>false</enabled>
113-
</releases>
114-
</pluginRepository>
115-
<pluginRepository>
116-
<id>spring-milestones</id>
117-
<name>Spring Milestones</name>
118-
<url>https://repo.spring.io/libs-milestone-local</url>
119-
<snapshots>
120-
<enabled>false</enabled>
121-
</snapshots>
122-
</pluginRepository>
123-
<pluginRepository>
124-
<id>spring-releases</id>
125-
<name>Spring Releases</name>
126-
<url>https://repo.spring.io/libs-release-local</url>
127-
<snapshots>
128-
<enabled>false</enabled>
129-
</snapshots>
130-
</pluginRepository>
131-
</pluginRepositories>
65+
66+
<build>
67+
<plugins>
68+
<plugin>
69+
<groupId>org.springframework.boot</groupId>
70+
<artifactId>spring-boot-maven-plugin</artifactId>
71+
</plugin>
72+
</plugins>
73+
</build>
74+
13275
</project>

samples/uppercase/src/main/java/functions/Application.java

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)