Skip to content

Commit 6aad5f2

Browse files
authored
Improve POM (#1)
* Various Maven POM improvements - Upgraded versions - Use the vertx-dependencies BOM to align dependencies * Use webSocketHandler instead of websocketHanbler Deprecated in 3.8.x, removed in v4 * Move to Vertx.next() Signed-off-by: Julien Ponge <jponge@redhat.com>
1 parent 61c1bd5 commit 6aad5f2

File tree

2 files changed

+18
-14
lines changed

2 files changed

+18
-14
lines changed

pom.xml

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,51 +6,55 @@
66

77
<groupId>kafka.vertx</groupId>
88
<artifactId>demo</artifactId>
9-
<version>0.0.1</version>
9+
<version>0.0.2-SNAPSHOT</version>
1010

1111
<properties>
1212
<kafka.version>2.3.0</kafka.version>
13-
<vertx.version>3.8.4</vertx.version>
13+
<vertx.version>4.0.0-SNAPSHOT</vertx.version>
1414
</properties>
1515

16-
<dependencies>
16+
<dependencyManagement>
17+
<dependencies>
18+
<dependency>
19+
<groupId>io.vertx</groupId>
20+
<artifactId>vertx-dependencies</artifactId>
21+
<version>${vertx.version}</version>
22+
<type>pom</type>
23+
<scope>import</scope>
24+
</dependency>
25+
</dependencies>
26+
</dependencyManagement>
1727

28+
<dependencies>
1829
<dependency>
1930
<groupId>io.vertx</groupId>
2031
<artifactId>vertx-core</artifactId>
21-
<version>${vertx.version}</version>
2232
</dependency>
2333
<dependency>
2434
<groupId>io.vertx</groupId>
2535
<artifactId>vertx-web</artifactId>
26-
<version>${vertx.version}</version>
2736
</dependency>
2837
<dependency>
2938
<groupId>io.vertx</groupId>
3039
<artifactId>vertx-kafka-client</artifactId>
31-
<version>${vertx.version}</version>
3240
</dependency>
3341
<dependency>
3442
<groupId>io.vertx</groupId>
3543
<artifactId>vertx-service-proxy</artifactId>
36-
<version>${vertx.version}</version>
3744
</dependency>
3845
<dependency>
3946
<groupId>io.vertx</groupId>
4047
<artifactId>vertx-codegen</artifactId>
41-
<version>${vertx.version}</version>
4248
<scope>provided</scope>
4349
</dependency>
4450
<dependency>
4551
<groupId>io.vertx</groupId>
4652
<artifactId>vertx-codegen</artifactId>
47-
<version>${vertx.version}</version>
4853
<classifier>processor</classifier>
4954
</dependency>
5055
<dependency>
5156
<groupId>io.vertx</groupId>
5257
<artifactId>vertx-config</artifactId>
53-
<version>${vertx.version}</version>
5458
</dependency>
5559
</dependencies>
5660

@@ -59,7 +63,7 @@
5963
<plugins>
6064
<plugin>
6165
<artifactId>maven-compiler-plugin</artifactId>
62-
<version>3.1</version>
66+
<version>3.8.1</version>
6367
<configuration>
6468
<source>1.8</source>
6569
<target>1.8</target>
@@ -71,7 +75,7 @@
7175
<plugin>
7276
<groupId>org.apache.maven.plugins</groupId>
7377
<artifactId>maven-shade-plugin</artifactId>
74-
<version>2.3</version>
78+
<version>3.2.2</version>
7579
<executions>
7680
<execution>
7781
<phase>package</phase>
@@ -91,7 +95,7 @@
9195
</transformers>
9296
<artifactSet>
9397
</artifactSet>
94-
<outputFile>${project.build.directory}/${project.artifactId}-${project.version}-fat.jar</outputFile>
98+
<outputFile>${project.build.directory}/${project.artifactId}-${project.version}-all.jar</outputFile>
9599
</configuration>
96100
</execution>
97101
</executions>

src/main/java/kafka/vertx/demo/websocket/WebsocketVerticle.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public void start(Promise<Void> done) {
3030
HttpServer server = vertx.createHttpServer();
3131
Router router = Router.router(vertx);
3232
router.get().handler(StaticHandler.create());
33-
server.websocketHandler(websocket -> {
33+
server.webSocketHandler(websocket -> {
3434
String path = websocket.path();
3535
if (PRODUCE_PATH.equals(path)) {
3636
handleProduceSocket(websocket);

0 commit comments

Comments
 (0)