rocketmq icon indicating copy to clipboard operation
rocketmq copied to clipboard

[Bug] Error parsing ipv6 from address in HAProxyMessageForwarder

Open yuz10 opened this issue 1 year ago • 0 comments

Before Creating the Bug Report

  • [X] I found a bug, not just asking a question, which should be created in GitHub Discussions.

  • [X] I have searched the GitHub Issues and GitHub Discussions of this repository and believe that this is not a duplicate.

  • [X] I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.

Runtime platform environment

Ubuntu 24.04

RocketMQ version

5.2.0

JDK Version

1.8

Describe the Bug

image

Steps to Reproduce

use ipv6 localhost (::1)

What Did You Expect to See?

succuss

What Did You See Instead?

Forward HAProxyMessage from Remoting to gRPC server error. java.lang.IllegalArgumentException: invalid IPv4 address: 0 at io.netty.handler.codec.haproxy.HAProxyMessage.checkAddress(HAProxyMessage.java:444) at io.netty.handler.codec.haproxy.HAProxyMessage.(HAProxyMessage.java:101) at test.HAProxyMessageForwarder.buildHAProxyMessage(HAProxyMessageForwarder.java:151) at test.HAProxyMessageForwarder.forwardHAProxyMessage(HAProxyMessageForwarder.java:76) at test.HAProxyMessageForwarder.channelRead(HAProxyMessageForwarder.java:61)

Additional Context

No response

yuz10 avatar Jun 05 '24 08:06 yuz10