You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2020/05/31 06:19:30 UTC
[GitHub] [pulsar] liudezhi2098 opened a new issue #7115: When the content of the sent message is 5M, it will appear that the current Topic can no longer send the message
liudezhi2098 opened a new issue #7115:
URL: https://github.com/apache/pulsar/issues/7115
**Describe the bug**
When the content of the sent message is 5M, it will appear that the current topic can no longer send the message.
*Send a message*
```java
byte[] data = new byte[5 * 1024 * 1024];
producer.newMessage().value(data).send();
```
*bookie has always been wrong io.netty.handler.codec.TooLongFrameException: Adjusted frame length exceeds 5242880: 5242992 - discarded*
```bash
bookie-io-1-26] ERROR org.apache.bookkeeper.proto.BookieRequestHandler - Unhandled exception occurred in I/O thread or handler
io.netty.handler.codec.TooLongFrameException: Adjusted frame length exceeds 5242880: 5242992 - discarded
at io.netty.handler.codec.LengthFieldBasedFrameDecoder.fail(LengthFieldBasedFrameDecoder.java:513) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.LengthFieldBasedFrameDecoder.failIfNecessary(LengthFieldBasedFrameDecoder.java:491) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.LengthFieldBasedFrameDecoder.exceededFrameLength(LengthFieldBasedFrameDecoder.java:378) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode(LengthFieldBasedFrameDecoder.java:421) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.LengthFieldBasedFrameDecoder.decode(LengthFieldBasedFrameDecoder.java:334) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.ByteToMessageDecoder.decodeRemovalReentryProtection(ByteToMessageDecoder.java:503) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:442) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:281) ~[io.netty-netty-codec-4.1.43.Final.jar:4.1.43.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:374) [io.netty-netty-transport-4.1.43.Final.jar:4.1.43.Final]
```
Bookie default configuration nettyMaxFrameSizeBytes is 5242880
but broker set NettyMaxFrameSizeBytes (conf.getMaxMessageSize() Commands.MESSAGE_SIZE_FRAME_PADDING);
```
bk_server.conf
# The maximum netty frame size in bytes. Any message received larger than this will be rejeted. Default value is 5MB.
# nettyMaxFrameSizeBytes=5242880
broker.conf
# Max size of messages.
maxMessageSize=5242880
```
So the broker thinks that the 5M message can be sent normally, but the bookie thinks it has exceeded the length, and bkclient will keep retrying.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] codelipenghui closed issue #7115: When the content of the sent message is 5M, it will appear that the current Topic can no longer send the message
Posted by GitBox <gi...@apache.org>.
codelipenghui closed issue #7115:
URL: https://github.com/apache/pulsar/issues/7115
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org