我在RAD 8.5 for Websphere 8.5中生成了一个自上而下的JAX-WS Web服务。
我想使用ServletContextListener初始化部署在websphere上的webservice应用程序的log4j设置。
我创建了一个实现ServletContextListener和ServletContextAttributeListener的侦听器,并将@WebListener注释添加到类中(而不是将其放在web.xml中),但是在启动Web服务应用程序时不会调用它。
根据this链接
WEB-INF / web.xml文件。 web.xml不包含servlet或 servlet-mapping元素。 WebSphere Application Server运行时 在模块加载时动态定义它们。
我需要做什么才能使我的log4j设置初始化或换句话说确保调用侦听器?