tomcat启动报错:too low setting for -Xss
Caused by: java.lang.IllegalStateException: Unable to complete the scan for annotations for web application [] due to a StackOverflowError. Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies. The class hierarchy being processed was [org.bouncycastle.asn1.ASN1EncodableVector->org.bouncycastle.asn1.DEREncodableVector->org.bouncycastle.asn1.ASN1EncodableVector]
原因:是因为tomcat启动的时候会去扫描jar包,看错误信息org.bouncycastle.asn1.ASN1EncodableVector,是出在这个类
这个类似出现在bcprov*.jar这个包
解决:修改Tomcat的catalina.properties配置文件
修改为 tomcat.util.scan.DefaultJarScanner.jarsToSkip=bcprov*.jar
加上bcprov*.jar这个过滤就可以,重启tomcat,可以正常启动