Java问题收录

在开发中我们经常遇到一些细节问题,如配置、IDE等,此时最常用的方法就是在浏览器搜索该问题的解决方案,但是网上的解决方案参差不齐,而且很多是相互抄袭,不仅解决不了问题,而且严重浪费时间。鉴于此,我将一些自己曾经遇到的问题,搜索出的有帮助或有启发的解决方案收录于此,方便读者和自己进行快速使用,节省时间。

log4j2的pom配置

IntelliJ运行时无法决定JDK的问题

Spring beans的问题

Exception in thread "main" org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from class path resource [applicationContext.xml]; nested exception is java.lang.NoSuchMethodError: org.springframework.beans.factory.xml.XmlReaderContext.getEnvironment()Lorg/springframework/core/env/Environment;

JDBC配置加载问题

Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'realtimeDataSource' defined in class path resource [applicationContext.xml]: Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'java.lang.String' to required type 'int' for property 'maxActive'; nested exception is java.lang.NumberFormatException: For input string: "${jdbc.maxActive}"

猜你喜欢

转载自blog.csdn.net/u010248374/article/details/78203835