Skip to content

Commit 08195db

Browse files
committed
docs(wildcard): Add wildcard priority docs
1 parent 7d6ed52 commit 08195db

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/docs/reactive-commons/10-wildcards.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
sidebar_position: 10
33
---
44

5-
### Wildcards
5+
# Wildcards
66

77
You may need to listen variable event names that have the same structure, in that case you have the method `handleDynamicEvents` in the `HandlerRegistry`, so you can specify a pattern with '*' wildcard, it does not creates a binding in the broker, but allows that you do it dynamically through a `DynamicRegistry` class.
88

99
You can also create binding with '#' wildcard, it is used to listen multiple words, for example `animals.#` will listen to `animals.dog`, `animals.dog.bark`, `animals.cat`, `animals.cat.meow`, etc.
1010

11-
#### DynamicRegistry API
11+
## DynamicRegistry API
1212

1313
```java
1414
public interface DynamicRegistry {
@@ -78,7 +78,7 @@ public class HandlerRegistryConfiguration {
7878

7979
This last approach is useful when you have a dynamic event name, for example, you can have a `purchase.cancelled` event, but you can also have a `purchase.cancelled.2021` event, so you can listen to all of them with `purchase.*` or `purchase.#` respectively.
8080

81-
# Priorities
81+
## Priorities
8282

8383
The handlers with wildcards have the lowest priority, so if you have a specific handler for an event name, it will be called before the wildcard handler.
8484

0 commit comments

Comments
 (0)