小白紧急求救,关于BeanFactory not initialized or already closed
赵自行 2014-10-10 01:36:08 这几天安装tomcat+CAS中,其中在连接数据库的时候网页出现出现The requested resource is not available的404错误。tomcat的log中记录错误为Exception sending context destroyed event to listener instance of class org.jasig.cas.web.init.SafeContextLoaderListener
java.lang.IllegalStateException: BeanFactory not initialized or already closed - call 'refresh' before accessing beans via the ApplicationContext。
网上查找错误原因说是ApplicationContext ctx = new ClassPathXmlApplicationContext();没有指定applicationContext.xml;我就一直纳闷与这句话在哪儿?我没有写过java文件,更不要提这句话了!