AsyncTCP splits my tcp message in two messages on my ESP32s3

I am trying to send a json string over a TCP connection to my ESP32 to configure the device.
I use the AsyncTCP library and the communication went without problems so far.
To receive messages I use the onData event.

Now I have added some more configuration parameters to the json string and the message I receive is split into two messages.

I suspect that my configuration string is exceeding some sort of input buffer, since it was working with a smaller message.

Is there any way to increase the size of the input buffer?

How long is your JSON string?

Information on TCP is transmitted in packets, the size of which is limited to approximately 1400 -1500 bytes. There is no way to increase this limit.

My message is getting split at a size of 1436 bytes.

Is the best solution to check the size of the message and combine it with the next message if it exceeds the 1436 bytes or is there a better solution?

if your data consists of several independent parts, then it is better to send these parts as separate messages.
If the message is large and not divided, you need to figure out how to handle multi-packet message in this library

Okay, thanks for your help