You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Rainer Jung <ra...@kippdata.de> on 2026/01/23 13:19:30 UTC

Details on Java 8 failures for TestStartupIPv6Connectors

I did some debugging: for Java 8 (failing) and Java 11+ (OK), the test 
case testIPv6LinkLocal use the same link local address in 
TestStartupIPv6Connectors. For example:

fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a

But in org.apache.coyote.AbstractProcessor.parseHost(), different values 
appear. For Java 8:

[fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:PORTNUM

For Java 11+:

[fe80:0:0:0:2e0:4cff:fee2:a74a]:PORTNUM

The thread name in both cases is 
http-nio-fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1.

The % character in the Java 8 case leads to a failure in parseHost 
(german error strings):

     [junit] 23-Jan-2026 14:09:43.062 INFORMATION 
[http-nio-fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1] 
org.apache.coyote.AbstractProcessor.parseHost Der Host 
[[fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:38323] ist nicht gültig.
     [junit]  Info: Weitere Vorkommen von Fehlern beim Parsen der 
Anfragen werden mit DEBUG Level ausgegeben
     [junit]     java.lang.IllegalArgumentException: Das Zeichen [%] ist 
kein valides Zeichen in einer IPv6 Addresse.
     [junit]             at 
org.apache.tomcat.util.http.parser.HttpParser.readHostIPv6(HttpParser.java:901)

Some there is some conversion involved for the more modern Java 
versions, that prevent the failure.

Regards,

Rainer








---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: Details on Java 8 failures for TestStartupIPv6Connectors

Posted by Rainer Jung <ra...@kippdata.de>.
Am 02.02.26 um 23:40 schrieb Mark Thomas:
> On 23/01/2026 13:19, Rainer Jung wrote:
>> I did some debugging: for Java 8 (failing) and Java 11+ (OK), the test 
>> case testIPv6LinkLocal use the same link local address in 
>> TestStartupIPv6Connectors. For example:
>>
>> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a
>>
>> But in org.apache.coyote.AbstractProcessor.parseHost(), different 
>> values appear. For Java 8:
>>
>> [fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:PORTNUM
>>
>> For Java 11+:
>>
>> [fe80:0:0:0:2e0:4cff:fee2:a74a]:PORTNUM
>>
>> The thread name in both cases is http-nio- 
>> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1.
>>
>> The % character in the Java 8 case leads to a failure in parseHost 
>> (german error strings):
> 
> I've tracked this down. This issue is this bug:
> 
> https://bugs.openjdk.org/browse/JDK-8027308
> 
> This has never been applied to Java 8:
> 
> https://github.com/openjdk/jdk11u/ 
> commit/66135672e1fb2290834277d9c359478fff4ddd12
> 
> I've configured this test to be skipped on Java < 11.

Thanks for finding the root cause. Interesting, that they never fixed it 
for Java 8, only 9+.

Best regards,

Rainer

> Mark
> 
>>
>>      [junit] 23-Jan-2026 14:09:43.062 INFORMATION [http-nio- 
>> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1] 
>> org.apache.coyote.AbstractProcessor.parseHost Der Host 
>> [[fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:38323] ist nicht gültig.
>>      [junit]  Info: Weitere Vorkommen von Fehlern beim Parsen der 
>> Anfragen werden mit DEBUG Level ausgegeben
>>      [junit]     java.lang.IllegalArgumentException: Das Zeichen [%] 
>> ist kein valides Zeichen in einer IPv6 Addresse.
>>      [junit]             at 
>> org.apache.tomcat.util.http.parser.HttpParser.readHostIPv6(HttpParser.java:901)
>>
>> Some there is some conversion involved for the more modern Java 
>> versions, that prevent the failure.
>>
>> Regards,
>>
>> Rainer

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Re: Details on Java 8 failures for TestStartupIPv6Connectors

Posted by Mark Thomas <ma...@apache.org>.
On 23/01/2026 13:19, Rainer Jung wrote:
> I did some debugging: for Java 8 (failing) and Java 11+ (OK), the test 
> case testIPv6LinkLocal use the same link local address in 
> TestStartupIPv6Connectors. For example:
> 
> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a
> 
> But in org.apache.coyote.AbstractProcessor.parseHost(), different values 
> appear. For Java 8:
> 
> [fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:PORTNUM
> 
> For Java 11+:
> 
> [fe80:0:0:0:2e0:4cff:fee2:a74a]:PORTNUM
> 
> The thread name in both cases is http-nio- 
> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1.
> 
> The % character in the Java 8 case leads to a failure in parseHost 
> (german error strings):

I've tracked this down. This issue is this bug:

https://bugs.openjdk.org/browse/JDK-8027308

This has never been applied to Java 8:

https://github.com/openjdk/jdk11u/commit/66135672e1fb2290834277d9c359478fff4ddd12

I've configured this test to be skipped on Java < 11.

Mark

> 
>      [junit] 23-Jan-2026 14:09:43.062 INFORMATION [http-nio- 
> fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a-auto-3-exec-1] 
> org.apache.coyote.AbstractProcessor.parseHost Der Host 
> [[fe80:0:0:0:2e0:4cff:fee2:a74a%enx00e04ce2a74a]:38323] ist nicht gültig.
>      [junit]  Info: Weitere Vorkommen von Fehlern beim Parsen der 
> Anfragen werden mit DEBUG Level ausgegeben
>      [junit]     java.lang.IllegalArgumentException: Das Zeichen [%] ist 
> kein valides Zeichen in einer IPv6 Addresse.
>      [junit]             at 
> org.apache.tomcat.util.http.parser.HttpParser.readHostIPv6(HttpParser.java:901)
> 
> Some there is some conversion involved for the more modern Java 
> versions, that prevent the failure.
> 
> Regards,
> 
> Rainer
> 
> 
> 
> 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: dev-help@tomcat.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org