diff --git a/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyExceptionHandlerSpec.groovy b/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyExceptionHandlerSpec.groovy index e19eb4860..cb5c0ecab 100644 --- a/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyExceptionHandlerSpec.groovy +++ b/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyExceptionHandlerSpec.groovy @@ -15,7 +15,7 @@ import io.micronaut.http.annotation.Get import io.micronaut.http.client.HttpClient import io.micronaut.http.client.annotation.Client import io.micronaut.http.client.exceptions.HttpClientResponseException -import io.micronaut.http.filter.OncePerRequestHttpServerFilter +import io.micronaut.http.filter.HttpServerFilter import io.micronaut.http.filter.ServerFilterChain import io.micronaut.http.server.exceptions.ExceptionHandler import io.micronaut.test.extensions.spock.annotation.MicronautTest @@ -98,10 +98,9 @@ class JettyExceptionHandlerSpec extends Specification { @Singleton @Filter("/**") @Requires(property = "spec.name", value = "JettyExceptionHandlerSpec") - static class MyFilter extends OncePerRequestHttpServerFilter { - + static class MyFilter implements HttpServerFilter { @Override - protected Publisher> doFilterOnce(HttpRequest request, ServerFilterChain chain) { + Publisher> doFilter(HttpRequest request, ServerFilterChain chain) { if (!request.getAttribute(HttpAttributes.ROUTE_MATCH).isPresent()) { return Publishers.just(new Unauthorized()) } diff --git a/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyPrincipalBindingSpec.groovy b/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyPrincipalBindingSpec.groovy index 913f958c0..3e7fc7052 100644 --- a/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyPrincipalBindingSpec.groovy +++ b/http-server-jetty/src/test/groovy/io/micronaut/servlet/jetty/JettyPrincipalBindingSpec.groovy @@ -63,9 +63,9 @@ class JettyPrincipalBindingSpec extends Specification { @Requires(property = 'spec.name', value = 'JettyPrincipalBindingSpec') @Singleton - static class AuthenticationProviderUserPassword implements AuthenticationProvider { + static class AuthenticationProviderUserPassword implements AuthenticationProvider { @Override - Publisher authenticate(HttpRequest httpRequest, AuthenticationRequest authenticationRequest) { + Publisher authenticate(T httpRequest, AuthenticationRequest authenticationRequest) { Mono.create({ MonoSink emitter -> String identity = authenticationRequest.identity if (identity == 'sherlock' && authenticationRequest.secret == 'password') { diff --git a/http-server-tomcat/src/test/groovy/io/micronaut/servlet/tomcat/TomcatPrincipalBindingSpec.groovy b/http-server-tomcat/src/test/groovy/io/micronaut/servlet/tomcat/TomcatPrincipalBindingSpec.groovy index 4df6ae424..d40f41208 100644 --- a/http-server-tomcat/src/test/groovy/io/micronaut/servlet/tomcat/TomcatPrincipalBindingSpec.groovy +++ b/http-server-tomcat/src/test/groovy/io/micronaut/servlet/tomcat/TomcatPrincipalBindingSpec.groovy @@ -63,9 +63,9 @@ class TomcatPrincipalBindingSpec extends Specification { @Requires(property = 'spec.name', value = 'TomcatPrincipalBindingSpec') @Singleton - static class AuthenticationProviderUserPassword implements AuthenticationProvider { + static class AuthenticationProviderUserPassword implements AuthenticationProvider { @Override - Publisher authenticate(HttpRequest httpRequest, AuthenticationRequest authenticationRequest) { + Publisher authenticate(T httpRequest, AuthenticationRequest authenticationRequest) { Mono.create({ MonoSink emitter -> String identity = authenticationRequest.identity if (identity == 'sherlock' && authenticationRequest.secret == 'password') { diff --git a/http-server-undertow/src/test/groovy/io/micronaut/servlet/undertow/UndertowPrincipalBindingSpec.groovy b/http-server-undertow/src/test/groovy/io/micronaut/servlet/undertow/UndertowPrincipalBindingSpec.groovy index d3accdfa0..984b5112d 100644 --- a/http-server-undertow/src/test/groovy/io/micronaut/servlet/undertow/UndertowPrincipalBindingSpec.groovy +++ b/http-server-undertow/src/test/groovy/io/micronaut/servlet/undertow/UndertowPrincipalBindingSpec.groovy @@ -63,9 +63,9 @@ class UndertowPrincipalBindingSpec extends Specification { @Requires(property = 'spec.name', value = 'UndertowPrincipalBindingSpec') @Singleton - static class AuthenticationProviderUserPassword implements AuthenticationProvider { + static class AuthenticationProviderUserPassword implements AuthenticationProvider { @Override - Publisher authenticate(HttpRequest httpRequest, AuthenticationRequest authenticationRequest) { + Publisher authenticate(T httpRequest, AuthenticationRequest authenticationRequest) { Mono.create({ MonoSink emitter -> String identity = authenticationRequest.identity if (identity == 'sherlock' && authenticationRequest.secret == 'password') {