@Singleton @Requires(property="micronaut.router.versioning.enabled",value="true") @Requires(beans=RoutesVersioningConfiguration.class) public class VersionAwareRouterListener extends Object implements BeanCreatedEventListener<Router>
Router with version matching logic.| Constructor and Description |
|---|
VersionAwareRouterListener(VersionRouteMatchFilter filter)
Creates a configuration to decorate existing
Router beans with a FilteredRouter. |
| Modifier and Type | Method and Description |
|---|---|
Router |
onCreated(BeanCreatedEvent<Router> event)
Returns a wrapped
Router to FilteredRouter. |
public VersionAwareRouterListener(VersionRouteMatchFilter filter)
Router beans with a FilteredRouter.filter - A VersionRouteMatchFilter to delegate routes filteringpublic Router onCreated(BeanCreatedEvent<Router> event)
Router to FilteredRouter.onCreated in interface BeanCreatedEventListener<Router>event - The Router bean created event