Grouping
Last updated
Last updated
KubeMQ supports grouping receivers with the same subscription channel patterns to form a load balancing group.
The group pattern is a useful pattern for sharing message load handling between services and for redundancy functionality too.
During a Subscription request, the receiver can set the group name to join or not. Based on the Group value setting KubeMQ will deliver messages to the receiver as follows:
Any receiver without a group setting (group="", blank)
Only one receiver for each group he belongs to
Example:
In the table below we have 8 receivers which subscribe to different channels and groups:
Receiver Name | Channel | Group |
R1 |
|
|
R2 |
|
|
R3 |
|
|
R4 |
|
|
R5 |
|
|
R6 |
|
|
R7 |
|
|
R8 |
|
|
In the table below, we explore several message channels and which receiver will get them:
Sending Message to Channel | Receivers |
| R6,R7 |
| R1, R2 or R3, R4 or R5, R6, R8 |
| R1, R2 or R3, R6, R8 |