Commit 7002f95
committed
Fix: Require latency monitoring domain to match prefix
Latency monitoring domains are an under-documented feature of
BlazingMQ that can be used to measure end-to-end message latency
through the broker. To support partition-aware latency measurement,
the broker parses queue names on these domains using this
regex (src/groups/mqb/mqbc/mqbc_clusterstate.cpp:765):
^\S+\.([0-9]+)\.\S+\.\S+$
An example string that matches this is:
foo.2.bar.baz
If a queue name matches this regex, the integer in the second
component (e.g., `2` in `foo.2.bar.baz`) is treated as the target
partition, and the queue is assigned to that partition.
Latency monitoring domains are expected to start with a configured
prefix (by default `bmq.sys.latemon.latency`, see
src/groups/mqb/mqbcfg/mqbcfg.xsd:102). However, the existing
implementation matches the configured prefix *anywhere* within the
domain name. This patch fixes this behavior: domains are not
recognized as latency monitoring domains only if they begin with the
configured prefix.
Signed-off-by: Patrick M. Niedzielski <patrick@pniedzielski.net>1 parent 89e90cc commit 7002f95
2 files changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
523 | 523 | | |
524 | 524 | | |
525 | 525 | | |
526 | | - | |
| 526 | + | |
527 | 527 | | |
528 | 528 | | |
529 | 529 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| |||
0 commit comments