Skip to content
Guy M. Allard edited this page Mar 8, 2018 · 3 revisions

STOMP specification levels 1.1 and 1.2 specify in detail a heart-beating mechanism that may optionally be used between a STOMP client and a message broker.

This mechanism can be used to test the health of the underlying TCP connection.

References:

The specifications do not prohibit extreme heartbeat values. For example a value of '1,1' is technically allowed. This is unlikely to function very well for either the client or the broker.

Rules of thumb for heartbeat value specification:

  • Do choose heartbeat values as large as possible, while still meeting the requirements for your application's environment.
  • Do not choose extremely low heartbeat values. This wastes client and server resources.
  • Be aware that broker implementations may not function per the STOMP specifications.
  • Be aware that brokers may restrict the range of values that can be used.
Clone this wiki locally