在网页运行的时候出现的错误...为什么不能实例化bean
在控制层中已经用annotation配置了的
Struts has detected an unhandled exception:
Messages: Could not instantiate bean class [cn.insurance.view.action.InsuranceInfoAction]: Constructor threw exception; nested exception is java.lang.StackOverflowError
Error creating bean with name 'insuranceInfoAction' defined in file [D:\Program Files\apache-tomcat-6.0.36\webapps\InsuranceRemind\WEB-INF\classes\cn\insurance\view\action\InsuranceInfoAction.class]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cn.insurance.view.action.InsuranceInfoAction]: Constructor threw exception; nested exception is java.lang.StackOverflowError
Unable to instantiate Action, insuranceInfoAction, defined for 'insuranceInfoAction_uploadExcelUI' in namespace '/'Error creating bean with name 'insuranceInfoAction' defined in file [D:\Program Files\apache-tomcat-6.0.36\webapps\InsuranceRemind\WEB-INF\classes\cn\insurance\view\action\InsuranceInfoAction.class]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cn.insurance.view.action.InsuranceInfoAction]: Constructor threw exception; nested exception is java.lang.StackOverflowError
File: org/springframework/beans/BeanUtils.java
Line number: 115
Stacktraces
Unable to instantiate Action, insuranceInfoAction, defined for 'insuranceInfoAction_uploadExcelUI' in namespace '/'Error creating bean with name 'insuranceInfoAction' defined in file [D:\Program Files\apache-tomcat-6.0.36\webapps\InsuranceRemind\WEB-INF\classes\cn\insurance\view\action\InsuranceInfoAction.class]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cn.insurance.view.action.InsuranceInfoAction]: Constructor threw exception; nested exception is java.lang.StackOverflowError
Struts.xml
/WEB-INF/jsp/dateAction/uploadExcelUI.jsp
insuranceInfoAction.java --控制层
@Component("insuranceInfoAction")
@Scope("prototype")
public class InsuranceInfoAction extends ModelDriverBaseAction{
//文件上传--excle后缀.xls
// public String addExcelData() {
//
//
// return "addExcelData";
// }
//上传页面-Excle
public String uploadExcelUI() {
return "uploadExcelUI";
}
}