Akka huge message size, how to know size before sending message

Hello. I am using akka clsuster sharding with Aeron remote. I have a problem with huge messages. Messages can carry a huge payload, and sometimes I have Aeron delivery exceptions. It’s possible to split a message with a huge payload, but how do you know the size of the message before delivery?
If I knew the size of the message before delivery, I would build a MessageSplitter that can split the message into small pieces.
Maybe you know how to implement this in akka?