mirror of
https://github.com/jlengrand/vert.x.git
synced 2026-03-10 08:51:19 +00:00
Rework native tests by using profiles and dependencies don't use specific classifiers
This commit is contained in:
@@ -23,13 +23,13 @@ Runs the tests
|
||||
Vert.x supports native transport on BSD and Linux, to run the tests with native transport
|
||||
|
||||
```
|
||||
> mvn test -Dvertx.testNativeTransport=true
|
||||
> mvn test -PtestNativeTransport
|
||||
```
|
||||
|
||||
Vert.x supports domain sockets on Linux exclusively, to run the tests with domain sockets
|
||||
|
||||
```
|
||||
> mvn test -Dvertx.testNativeTransport=true -Dtest.useDomainSockets
|
||||
> mvn test -PtestDomainSockets
|
||||
```
|
||||
|
||||
Vert.x has a few integrations tests that run a differently configured JVM (classpath, system properties, etc....)
|
||||
|
||||
48
pom.xml
48
pom.xml
@@ -118,13 +118,11 @@
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-epoll</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>linux-x86_64</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-kqueue</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>osx-x86_64</classifier>
|
||||
</dependency>
|
||||
|
||||
<!-- Jackson -->
|
||||
@@ -680,6 +678,52 @@
|
||||
</build>
|
||||
</profile>
|
||||
|
||||
<!-- Run tests with native transport -->
|
||||
<profile>
|
||||
<id>testNativeTransport</id>
|
||||
<properties>
|
||||
<vertx.testNativeTransport>true</vertx.testNativeTransport>
|
||||
<vertx.testDomainSockets>false</vertx.testDomainSockets>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-epoll</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>linux-x86_64</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-kqueue</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>osx-x86_64</classifier>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
|
||||
<!-- Run tests with native transport and domain sockets -->
|
||||
<profile>
|
||||
<id>testDomainSockets</id>
|
||||
<properties>
|
||||
<vertx.testNativeTransport>true</vertx.testNativeTransport>
|
||||
<vertx.testDomainSockets>true</vertx.testDomainSockets>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-epoll</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>linux-x86_64</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-transport-native-kqueue</artifactId>
|
||||
<optional>true</optional>
|
||||
<classifier>osx-x86_64</classifier>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
|
||||
<!-- Documentation generation : activate with -Pdocs -->
|
||||
<profile>
|
||||
<id>docs</id>
|
||||
|
||||
@@ -1705,6 +1705,8 @@ You need to add the following dependency in your classpath:
|
||||
</dependency>
|
||||
----
|
||||
|
||||
MacOS Sierra and above are supported.
|
||||
|
||||
Native on BSD gives you extra networking options:
|
||||
|
||||
* SO_REUSEPORT
|
||||
|
||||
@@ -174,7 +174,7 @@ can be retrieved using `link:../../apidocs/io/vertx/core/net/NetSocket.html#remo
|
||||
Files and classpath resources can be written to the socket directly using `link:../../apidocs/io/vertx/core/net/NetSocket.html#sendFile-java.lang.String-[sendFile]`. This can be a very
|
||||
efficient way to send files, as it can be handled by the OS kernel directly where supported by the operating system.
|
||||
|
||||
Please see the chapter about <<classpath, serving files from the classpath>> for restrictions of the
|
||||
Please see the chapter about <<classpath, serving files from the classpath>> for restrictions of the
|
||||
classpath resolution or disabling it.
|
||||
|
||||
[source,java]
|
||||
@@ -473,7 +473,9 @@ NetServerOptions options = new NetServerOptions().
|
||||
NetServer server = vertx.createNetServer(options);
|
||||
----
|
||||
|
||||
Keep in mind that pem configuration, the private key is not crypted.
|
||||
PKCS8, PKCS1 and X.509 certificates wrapped in a PEM block formats are supported.
|
||||
|
||||
WARNING: keep in mind that pem configuration, the private key is not crypted.
|
||||
|
||||
==== Specifying trust for the server
|
||||
|
||||
|
||||
Reference in New Issue
Block a user