我有一个网络应用程序,web.xml我在其中添加了HttpSessionEventPublisher作为监听器.Web应用程序在Jetty 7.x上运行,我们使用的是Spring 3.1.1.
这应该是触发HttpSessionCreatedEvent和HttpSessionDestroyedEventSpring上下文事件监听器.
我有一个@Controller实现的Bean()ApplicationListener<ApplicationEvent>.ApplicationEvent是共同的父类的HttpSessionCreatedEvent和HttpSessionDestroyedEvent.当我现在登录到我的Web应用程序或从中退出时,我希望将这些事件触发到该onApplicationEvent(ApplicationEvent event)方法.我收到了一些其他事件,比如一些请求处理事件,但预期的事件没有显示出来.我已经跟踪了一下应用程序,HttpSessionEventPublisher肯定会将事件触发到上下文,但是没有接近监听器.我在这里想念什么?