What is the maximum message length for a MQTT broker

0 votes

I am using the node.js mosca MQTT broker for some internet of things (iot) application.

https://github.com/mcollina/mosca

What is the maximum message length that a topic can receive for the mosca broker? What are the factors that constrain the message length?

If I want to increase the message length, is there a configuration parameter I can modify or which part of the code can I change?

Jul 17, 2018 in IoT (Internet of Things) by Matt
• 2,270 points
9,052 views

1 answer to this question.

0 votes
It's not entirely clear what you're asking here, so I'll answer both possibilities.

The length of the actual topic string is at most 65536 bytes. This is a limit imposed by the mqtt spec, you can't change it. It is also worth noting that the topic is encoded with utf-8, so you may have less than 65536 characters available.

The payload of the message is limited to 268,435,456 bytes. Again, this is defined by the spec.

If you are routinely approaching either of these limits you should be thinking about whether what you are doing is sensible.
answered Jul 17, 2018 by anonymous2
• 4,280 points

Related Questions In IoT (Internet of Things)

0 votes
1 answer

What is the time taken by a 200 byte message for transmission in a beacon-enabled network?

Now, data rates of IEEE 802.15.4 are ...READ MORE

answered Aug 24, 2018 in IoT (Internet of Things) by Upasana
• 8,620 points
618 views
0 votes
1 answer
0 votes
1 answer

MQTT broker for Google App Engine

You had a hard time finding anything ...READ MORE

answered Aug 1, 2018 in IoT (Internet of Things) by nirvana
• 3,130 points
1,228 views
0 votes
1 answer

Where is published message stored by mosquitto broker if offline?

Well, of course, they are stored! That ...READ MORE

answered Aug 10, 2018 in IoT (Internet of Things) by nirvana
• 3,130 points
3,408 views
0 votes
1 answer

MQTT protocol connection error

Ok so you need two libraries to ...READ MORE

answered Jul 6, 2018 in IoT (Internet of Things) by anonymous2
• 4,280 points

reshown Jul 6, 2018 by Vardhan 2,786 views
0 votes
1 answer

Mosquitto 1.4.2 Websocket support

down vote In the dir mosquitto-1.4.X edit the ...READ MORE

answered Jul 9, 2018 in IoT (Internet of Things) by anonymous2
• 4,280 points
1,192 views
0 votes
1 answer

IoT request response protocol

Based on your requirement of a light ...READ MORE

answered Jul 13, 2018 in IoT (Internet of Things) by anonymous2
• 4,280 points
1,618 views
0 votes
1 answer

Node-RED, IOT Foundation Out Node Not Sending Commands

A simple test to check if the ...READ MORE

answered Jul 19, 2018 in IoT (Internet of Things) by TejaswiniUL
• 140 points
733 views
0 votes
1 answer

What is the size of CoAP packet?

It Depends: Core CoAP messages must be small enough ...READ MORE

answered Jul 17, 2018 in IoT (Internet of Things) by anonymous2
• 4,280 points
2,193 views
0 votes
1 answer

The MQTT folder is missing in Bluemix IoT NodeJS code,

IoT-Workbench now uses new improved code generation ...READ MORE

answered Aug 8, 2018 in IoT (Internet of Things) by anonymous2
• 4,280 points
687 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP