Skip to content

Commit a40edf5

Browse files
committed
Force use of IPv4 in native image
To avoid "Address family not supported by protocol" error on some environment. Caveat: IPv6 only hosts are no longer supported. Fixes #208
1 parent e997446 commit a40edf5

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ native-image: clean ## Build the native image
3434
--initialize-at-build-time=javax.servlet \
3535
--initialize-at-build-time=org.slf4j \
3636
--no-fallback \
37-
-H:IncludeResources="rabbitmq-perf-test.properties"
37+
-H:IncludeResources="rabbitmq-perf-test.properties" \
38+
-Djava.net.preferIPv4Stack=true
3839

3940
.PHONY: docker-image-dev
4041
docker-image-dev: ## Build Docker image with the local PerfTest version

src/docs/asciidoc/usage-advanced.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,8 @@ PerfTest native executable has also some limitations:
418418

419419
* link:#supported-metrics[JVM metrics] are not supported
420420
* it is not possible to configure logging
421-
* TLS is not supported
421+
* TLS is not supported (this is likely to be fixed someday)
422+
* IPv6 only hosts are not supported (this is likely to be fixed someday)
422423

423424
[WARNING]
424425
====

0 commit comments

Comments
 (0)