use of io.undertow.server.handlers.PathHandler in project wildfly by wildfly.
the class UndertowSubsystemTestCase method testCustomFilters.
private void testCustomFilters(KernelServices mainServices) {
ServiceController<FilterService> customFilter = (ServiceController<FilterService>) mainServices.getContainer().getService(UndertowService.FILTER.append("custom-filter"));
customFilter.setMode(ServiceController.Mode.ACTIVE);
FilterService connectionLimiterService = customFilter.getService().getValue();
HttpHandler result = connectionLimiterService.createHttpHandler(Predicates.truePredicate(), new PathHandler());
Assert.assertNotNull("handler should have been created", result);
}
use of io.undertow.server.handlers.PathHandler in project wildfly by wildfly.
the class UndertowSubsystem20TestCase method testCustomFilters.
private void testCustomFilters(KernelServices mainServices) {
ServiceController<FilterService> customFilter = (ServiceController<FilterService>) mainServices.getContainer().getService(UndertowService.FILTER.append("custom-filter"));
customFilter.setMode(ServiceController.Mode.ACTIVE);
FilterService connectionLimiterService = customFilter.getService().getValue();
HttpHandler result = connectionLimiterService.createHttpHandler(Predicates.truePredicate(), new PathHandler());
Assert.assertNotNull("handler should have been created", result);
}
Aggregations