Skip to content

Commit 4a500ea

Browse files
committed
Upgrade to Inverno 1.6.2
1 parent 09a63d4 commit 4a500ea

File tree

7 files changed

+111
-185
lines changed

7 files changed

+111
-185
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
FROM maven:3.8.2-openjdk-16 as maven
1+
FROM maven:3.9.6-amazoncorretto-21 as maven
22
WORKDIR /inverno
33
COPY src src
44
COPY pom.xml pom.xml
5-
RUN mvn package -q
5+
RUN mvn package -q -Pio.inverno.io_uring
66

77
EXPOSE 8080
88

99
# CMD [ "target/maven-inverno/application_linux_amd64/inverno-benchmark-1.0.0-SNAPSHOT/bin/inverno-benchmark" ]
1010
CMD export DBIP=`getent hosts tfb-database | awk '{ print $1 }'` && \
11-
target/maven-inverno/application_linux_amd64/inverno-benchmark-1.0.0-SNAPSHOT/bin/inverno-benchmark --com.techempower.inverno.benchmark.appConfiguration.db_host=\"$DBIP\"
11+
target/maven-inverno/application_linux_amd64/inverno-benchmark-1.0.0-SNAPSHOT/bin/inverno-benchmark --com.techempower.inverno.benchmark.appConfiguration.db_host=\"$DBIP\"
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
FROM maven:3.8.2-openjdk-16 as maven
1+
FROM maven:3.9.6-amazoncorretto-21 as maven
22
WORKDIR /inverno
33
COPY src src
44
COPY pom.xml pom.xml
5-
RUN mvn package -q
5+
RUN mvn package -q -Pio.inverno.io_uring
66

77
EXPOSE 8080
88

9-
CMD [ "target/maven-inverno/application_linux_amd64/inverno-benchmark-1.0.0-SNAPSHOT/bin/inverno-benchmark", "--com.techempower.inverno.benchmark.appConfiguration.boot.reactor_prefer_vertx=false" ]
9+
CMD [ "target/inverno-benchmark-1.0.0-SNAPSHOT-application_linux_amd64/bin/inverno-benchmark", "--com.techempower.inverno.benchmark.appConfiguration.boot.reactor_prefer_vertx=false" ]

frameworks/Java/inverno/pom.xml

Lines changed: 97 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<parent>
77
<groupId>io.inverno.dist</groupId>
88
<artifactId>inverno-parent</artifactId>
9-
<version>1.4.1</version>
9+
<version>1.6.2</version>
1010
</parent>
1111
<groupId>com.techempower</groupId>
1212
<artifactId>inverno-benchmark</artifactId>
@@ -17,9 +17,9 @@
1717
<description>Inverno framework benchmark test</description>
1818

1919
<properties>
20-
<maven.compiler.source>16</maven.compiler.source>
21-
<maven.compiler.target>16</maven.compiler.target>
22-
<maven.compiler.release>16</maven.compiler.release>
20+
<maven.compiler.source>21</maven.compiler.source>
21+
<maven.compiler.target>21</maven.compiler.target>
22+
<maven.compiler.release>21</maven.compiler.release>
2323
</properties>
2424

2525
<dependencies>
@@ -79,47 +79,109 @@
7979
<version>${version.netty}</version>
8080
</dependency>
8181

82-
<dependency>
82+
<!--<dependency>
8383
<groupId>io.netty</groupId>
8484
<artifactId>netty-transport-native-epoll</artifactId>
8585
<classifier>linux-x86_64</classifier>
86+
</dependency>-->
87+
88+
<dependency>
89+
<groupId>io.netty.incubator</groupId>
90+
<artifactId>netty-incubator-transport-native-io_uring</artifactId>
91+
<classifier>linux-x86_64</classifier>
92+
</dependency>
93+
94+
<dependency>
95+
<groupId>io.vertx</groupId>
96+
<artifactId>vertx-io_uring-incubator</artifactId>
8697
</dependency>
8798

8899
<dependency>
89100
<groupId>org.apache.logging.log4j</groupId>
90101
<artifactId>log4j-core</artifactId>
91102
</dependency>
92103
</dependencies>
93-
94-
<build>
95-
<plugins>
96-
<plugin>
97-
<groupId>io.inverno.tool</groupId>
98-
<artifactId>inverno-maven-plugin</artifactId>
99-
<executions>
100-
<execution>
101-
<id>inverno-package</id>
102-
<phase>package</phase>
103-
<goals>
104-
<goal>build-app</goal>
105-
</goals>
106-
<configuration>
107-
<vm>server</vm>
108-
<launchers>
109-
<launcher>
110-
<name>inverno-benchmark</name>
111-
<vmOptions>-Xms2g -Xmx2g -server -XX:+UseNUMA -XX:+UseParallelGC -Dio.netty.leakDetection.level=disabled -Dvertx.disableHttpHeadersValidation=true -Dvertx.disableMetrics=true -Dvertx.disableH2c=true -Dvertx.disableWebsockets=true -Dvertx.flashPolicyHandler=false -Dvertx.threadChecks=false -Dvertx.disableContextTimings=true -Dvertx.disableTCCL=true --add-modules io.netty.transport.unix.common,io.netty.transport.epoll</vmOptions>
112-
</launcher>
113-
</launchers>
114-
<formats>
115-
<format>zip</format>
116-
</formats>
117-
</configuration>
118-
</execution>
119-
</executions>
120-
</plugin>
121-
</plugins>
122-
</build>
104+
105+
<profiles>
106+
<profile>
107+
<id>io.inverno.epoll</id>
108+
<dependencies>
109+
<dependency>
110+
<groupId>io.netty</groupId>
111+
<artifactId>netty-transport-native-epoll</artifactId>
112+
<classifier>linux-x86_64</classifier>
113+
</dependency>
114+
</dependencies>
115+
<build>
116+
<plugins>
117+
<plugin>
118+
<groupId>io.inverno.tool</groupId>
119+
<artifactId>inverno-maven-plugin</artifactId>
120+
<executions>
121+
<execution>
122+
<id>inverno-package-app</id>
123+
<phase>package</phase>
124+
<goals>
125+
<goal>package-app</goal>
126+
</goals>
127+
<configuration>
128+
<vm>server</vm>
129+
<launchers>
130+
<launcher>
131+
<name>inverno-benchmark</name>
132+
<vmOptions>-Xms2g -Xmx2g -server -XX:+UseNUMA -XX:+UseParallelGC -Dio.netty.leakDetection.level=disabled -Dio.netty.buffer.checkBounds=false -Dio.netty.buffer.checkBounds=false -Dvertx.disableHttpHeadersValidation=true -Dvertx.disableMetrics=true -Dvertx.disableH2c=true -Dvertx.disableWebsockets=true -Dvertx.flashPolicyHandler=false -Dvertx.threadChecks=false -Dvertx.disableContextTimings=true -Dvertx.disableTCCL=true --add-modules io.netty.transport.unix.common,io.netty.transport.classes.epoll,io.netty.transport.epoll.linux.x86_64</vmOptions>
133+
</launcher>
134+
</launchers>
135+
<archiveFormats>
136+
<archiveFormat>zip</archiveFormat>
137+
</archiveFormats>
138+
</configuration>
139+
</execution>
140+
</executions>
141+
</plugin>
142+
</plugins>
143+
</build>
144+
</profile>
145+
<profile>
146+
<id>io.inverno.io_uring</id>
147+
<dependencies>
148+
<dependency>
149+
<groupId>io.netty</groupId>
150+
<artifactId>netty-transport-native-epoll</artifactId>
151+
<classifier>linux-x86_64</classifier>
152+
</dependency>
153+
</dependencies>
154+
<build>
155+
<plugins>
156+
<plugin>
157+
<groupId>io.inverno.tool</groupId>
158+
<artifactId>inverno-maven-plugin</artifactId>
159+
<executions>
160+
<execution>
161+
<id>inverno-package-app</id>
162+
<phase>package</phase>
163+
<goals>
164+
<goal>package-app</goal>
165+
</goals>
166+
<configuration>
167+
<vm>server</vm>
168+
<launchers>
169+
<launcher>
170+
<name>inverno-benchmark</name>
171+
<vmOptions>-Xms2g -Xmx2g -server -XX:+UseNUMA -XX:+UseParallelGC -Dio.netty.leakDetection.level=disabled -Dio.netty.buffer.checkBounds=false -Dio.netty.buffer.checkBounds=false -Dvertx.disableHttpHeadersValidation=true -Dvertx.disableMetrics=true -Dvertx.disableH2c=true -Dvertx.disableWebsockets=true -Dvertx.flashPolicyHandler=false -Dvertx.threadChecks=false -Dvertx.disableContextTimings=true -Dvertx.disableTCCL=true --add-modules io.netty.transport.unix.common,io.netty.incubator.transport.classes.io_uring,io.netty.incubator.transport.io_uring.linux.x86_64</vmOptions>
172+
</launcher>
173+
</launchers>
174+
<archiveFormats>
175+
<archiveFormat>zip</archiveFormat>
176+
</archiveFormats>
177+
</configuration>
178+
</execution>
179+
</executions>
180+
</plugin>
181+
</plugins>
182+
</build>
183+
</profile>
184+
</profiles>
123185

124186
</project>
125187

frameworks/Java/inverno/src/jmods/io.vertx.core/module-info.java

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

frameworks/Java/inverno/src/jmods/r2dbc.postgresql/module-info.java

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

frameworks/Java/inverno/src/main/java/com/techempower/inverno/benchmark/internal/Handler.java renamed to frameworks/Java/inverno/src/main/java/com/techempower/inverno/benchmark/internal/Controller.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,14 @@
2323
import io.inverno.mod.base.concurrent.Reactor;
2424
import io.inverno.mod.base.concurrent.ReactorScope;
2525
import io.inverno.mod.base.converter.ConverterException;
26+
import io.inverno.mod.http.base.ExchangeContext;
2627
import io.inverno.mod.http.base.HttpException;
2728
import io.inverno.mod.http.base.InternalServerErrorException;
2829
import io.inverno.mod.http.base.Parameter;
2930
import io.inverno.mod.http.base.Status;
3031
import io.inverno.mod.http.server.Exchange;
31-
import io.inverno.mod.http.server.ExchangeContext;
32-
import io.inverno.mod.http.server.RootExchangeHandler;
32+
import io.inverno.mod.http.server.ErrorExchange;
33+
import io.inverno.mod.http.server.ServerController;
3334
import io.inverno.mod.sql.SqlClient;
3435
import io.inverno.mod.sql.UnsafeSqlOperations;
3536
import io.netty.buffer.ByteBuf;
@@ -42,7 +43,7 @@
4243
import reactor.core.publisher.Mono;
4344

4445
@Bean( visibility = Visibility.PRIVATE )
45-
public class Handler implements RootExchangeHandler<ExchangeContext, Exchange<ExchangeContext>> {
46+
public class Controller implements ServerController<ExchangeContext, Exchange<ExchangeContext>, ErrorExchange<ExchangeContext>> {
4647

4748
private static final String PATH_PLAINTEXT = "/plaintext";
4849
private static final String PATH_JSON = "/json";
@@ -65,7 +66,7 @@ public class Handler implements RootExchangeHandler<ExchangeContext, Exchange<Ex
6566

6667
private CharSequence date;
6768

68-
public Handler(Reactor reactor,
69+
public Controller(Reactor reactor,
6970
ObjectMapper mapper,
7071
ReactorScope<Mono<SqlClient>> sqlClient
7172
) {

frameworks/Java/inverno/src/main/java/module-info.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
requires io.vertx.core;
1717
requires java.sql;
1818

19-
requires transitive io.netty.transport;
20-
requires static io.netty.transport.unix.common;
21-
requires static io.netty.transport.epoll;
19+
//requires transitive io.netty.transport;
20+
//requires static io.netty.transport.unix.common;
21+
//requires static io.netty.transport.epoll;
2222

2323
exports com.techempower.inverno.benchmark;
2424
exports com.techempower.inverno.benchmark.model;

0 commit comments

Comments
 (0)