At the moment, the gRPC extension is tied to the Jetty11HttpServer in the buildHttpServer method.
@Override
public HttpServer buildHttpServer(
Options options,
AdminRequestHandler adminRequestHandler,
StubRequestHandler stubRequestHandler) {
return new Jetty11HttpServer(options, adminRequestHandler, stubRequestHandler) {
@Override
protected void decorateMockServiceContextBeforeConfig(
ServletContextHandler mockServiceContext) {
final GrpcFilter grpcFilter = new GrpcFilter(stubRequestHandler, fileDescriptors);
final FilterHolder filterHolder = new FilterHolder(grpcFilter);
mockServiceContext.addFilter(filterHolder, "/*", EnumSet.of(DispatcherType.REQUEST));
}
};
}
This means it won't work anywhere where we need to rely on Jetty12 like the 3.x.x releases of Spring Boot. It would be nice to support both Jetty 11 and 12 like we do in WireMock core
Proposal
At the moment, the gRPC extension is tied to the
Jetty11HttpServer
in thebuildHttpServer
method.This means it won't work anywhere where we need to rely on Jetty12 like the 3.x.x releases of Spring Boot. It would be nice to support both Jetty 11 and 12 like we do in WireMock core
References
https://github.com/wiremock/wiremock/tree/master/wiremock-jetty12 https://wiremock-community.slack.com/archives/C04HHJ7F20G/p1715613366000319