I had a similar problem with Jetty 9.3.10
Have you tried to set the extended listener types to true? If it is set to false (default), ServletContextListener implementations will not be counted in org.eclipse.jetty.server.handler.ContextHandler.Context#checkListener
webapp.getServletContext().setExtendedListenerTypes(true);
RobertG
source share