eclipse-vertx/vert.x · error · IllegalArgumentException
Default HTTP client version ${protocolVersion} does not belo
Error message
Default HTTP client version ${protocolVersion} does not belong to the ALPN protocol version list ${versions} What it means
Consistency check while converting HttpClientOptions into HttpClientConfig: the configured default protocol version is not present in the ALPN application protocol list derived from the enabled SSL/ALPN versions. The message reports both the default version and the ALPN list; the mismatched configuration input is options.protocolVersion versus the ALPN-enabled versions.
Source
Thrown at vertx-core/src/main/java/io/vertx/core/http/HttpClientConfig.java:155
redirectConfig.setMaxBufferedSize(options.getMaxRedirectBufferedSize());
if (options.getCrossOriginRedirectBlockedHeaders() != null) {
redirectConfig.setCrossOriginBlockedHeaders(options.getCrossOriginRedirectBlockedHeaders());
}
if (options.getSameOriginRedirectBlockedHeaders() != null) {
redirectConfig.setSameOriginBlockedHeaders(options.getSameOriginRedirectBlockedHeaders());
}
List<HttpVersion> versions;
ClientSSLOptions sslOptions = options.getSslOptions();
if (sslOptions == null || !sslOptions.isUseAlpn() || sslOptions.getApplicationLayerProtocols().isEmpty()) {
versions = new ArrayList<>(toSupportedVersion(options.getProtocolVersion()));
} else {
versions = sslOptions.getApplicationLayerProtocols()
.stream()
.map(HttpVersion::fromAlpnName)
.collect(Collectors.toList());
if (!versions.contains(options.getProtocolVersion())) {
throw new IllegalArgumentException("Default HTTP client version " + options.getProtocolVersion() +
" does not belong to the ALPN protocol version list " + versions);
}
}
this.tcpConfig = new TcpClientConfig(options);
this.quicConfig = defaultQuicConfig();
this.ssl = options.isSsl();
this.versions = versions;
this.http1Config = options.getHttp1Config();
this.http2Config = options.getHttp2Config();
this.http3Config = new Http3ClientConfig();
this.verifyHost = options.isVerifyHost();
this.decompressionEnabled = options.isDecompressionSupported();
this.defaultHost = options.getDefaultHost();
this.defaultPort = options.getDefaultPort();
this.redirectConfig = redirectConfig;
this.observabilityConfig = observabilityConfig;
this.shared = options.isShared();View on GitHub (pinned to fb308bd8c3)
Solutions
- Enable ALPN versions that include the configured default protocol version
- Or set a default protocolVersion consistent with the ALPN list
- Disable ALPN if it is not needed
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at vertx-core/src/main/java/io/vertx/core/http/HttpClientConfig.java:155 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of eclipse-vertx/vert.x@fb308bd8c3 (2026-09-06).
Data as JSON: /api/errors/0f682b629e2be54f.
Report an issue: GitHub.