Bootstrap

关于java.lang.NoSuchMethodError: org.yaml.snakeyaml.LoaderOptions.setMaxAliasesForCollections(I)V报错的问题

这几天做一个项目的时候,出现了如下所示的错误:

07:17:04.750 [background-preinit] DEBUG org.hibernate.validator.messageinterpolation.ResourceBundleMessageInterpolator - Loaded expression factory via original TCCL
07:17:04.772 [background-preinit] DEBUG org.hibernate.validator.internal.engine.ValidatorFactoryImpl - HV000234: Using org.hibernate.validator.messageinterpolation.ResourceBundleMessageInterpolator as ValidatorFactory-scoped message interpolator.
07:17:04.772 [background-preinit] DEBUG org.hibernate.validator.internal.engine.ValidatorFactoryImpl - HV000234: Using org.hibernate.validator.internal.engine.resolver.TraverseAllTraversableResolver as ValidatorFactory-scoped traversable resolver.
07:17:04.772 [background-preinit] DEBUG org.hibernate.validator.internal.engine.ValidatorFactoryImpl - HV000234: Using org.hibernate.validator.internal.util.ExecutableParameterNameProvider as ValidatorFactory-scoped parameter name provider.
07:17:04.772 [background-preinit] DEBUG org.hibernate.validator.internal.engine.ValidatorFactoryImpl - HV000234: Using org.hibernate.validator.internal.engine.DefaultClockProvider as ValidatorFactory-scoped clock provider.
07:17:04.772 [background-preinit] DEBUG org.hibernate.validator.internal.engine.ValidatorFactoryImpl - HV000234: Using org.hibernate.validator.internal.engine.scripting.DefaultScriptEvaluatorFactory as ValidatorFactory-scoped script evaluator factory.
07:17:05.507 [main] DEBUG org.springframework.boot.context.logging.ClasspathLoggingApplicationListener - Application failed to start with classpath: [file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/charsets.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/deploy.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/access-bridge-64.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/cldrdata.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/dnsns.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/jaccess.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/jfxrt.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/localedata.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/nashorn.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/sunec.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/sunjce_provider.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/sunmscapi.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/sunpkcs11.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/ext/zipfs.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/javaws.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/jce.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/jfr.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/jfxswt.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/jsse.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/management-agent.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/plugin.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/resources.jar, file:/C:/Program%20Files/Java/jdk1.8.0_162/jre/lib/rt.jar, file:/D:/springbootCode/gulimalls/renren-fast/target/classes/, file:/D:/Apache/repository/org/yaml/snakeyaml/1.25/snakeyaml-1.25.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter/2.2.6.RELEASE/spring-boot-starter-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-logging/2.2.6.RELEASE/spring-boot-starter-logging-2.2.6.RELEASE.jar, file:/D:/Apache/repository/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3.jar, file:/D:/Apache/repository/ch/qos/logback/logback-core/1.2.3/logback-core-1.2.3.jar, file:/D:/Apache/repository/org/apache/logging/log4j/log4j-to-slf4j/2.12.1/log4j-to-slf4j-2.12.1.jar, file:/D:/Apache/repository/org/apache/logging/log4j/log4j-api/2.12.1/log4j-api-2.12.1.jar, file:/D:/Apache/repository/org/slf4j/jul-to-slf4j/1.7.30/jul-to-slf4j-1.7.30.jar, file:/D:/Apache/repository/jakarta/annotation/jakarta.annotation-api/1.3.5/jakarta.annotation-api-1.3.5.jar, file:/D:/Apache/repository/org/hamcrest/hamcrest/2.1/hamcrest-2.1.jar, file:/D:/Apache/repository/net/bytebuddy/byte-buddy/1.10.8/byte-buddy-1.10.8.jar, file:/D:/Apache/repository/org/springframework/spring-core/5.2.5.RELEASE/spring-core-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-jcl/5.2.5.RELEASE/spring-jcl-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-web/2.2.6.RELEASE/spring-boot-starter-web-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-json/2.2.6.RELEASE/spring-boot-starter-json-2.2.6.RELEASE.jar, file:/D:/Apache/repository/com/fasterxml/jackson/datatype/jackson-datatype-jdk8/2.10.3/jackson-datatype-jdk8-2.10.3.jar, file:/D:/Apache/repository/com/fasterxml/jackson/datatype/jackson-datatype-jsr310/2.10.3/jackson-datatype-jsr310-2.10.3.jar, file:/D:/Apache/repository/com/fasterxml/jackson/module/jackson-module-parameter-names/2.10.3/jackson-module-parameter-names-2.10.3.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-tomcat/2.2.6.RELEASE/spring-boot-starter-tomcat-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/apache/tomcat/embed/tomcat-embed-core/9.0.33/tomcat-embed-core-9.0.33.jar, file:/D:/Apache/repository/org/apache/tomcat/embed/tomcat-embed-el/9.0.33/tomcat-embed-el-9.0.33.jar, file:/D:/Apache/repository/org/apache/tomcat/embed/tomcat-embed-websocket/9.0.33/tomcat-embed-websocket-9.0.33.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-validation/2.2.6.RELEASE/spring-boot-starter-validation-2.2.6.RELEASE.jar, file:/D:/Apache/repository/jakarta/validation/jakarta.validation-api/2.0.2/jakarta.validation-api-2.0.2.jar, file:/D:/Apache/repository/org/hibernate/validator/hibernate-validator/6.0.18.Final/hibernate-validator-6.0.18.Final.jar, file:/D:/Apache/repository/org/jboss/logging/jboss-logging/3.4.1.Final/jboss-logging-3.4.1.Final.jar, file:/D:/Apache/repository/org/springframework/spring-web/5.2.5.RELEASE/spring-web-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-webmvc/5.2.5.RELEASE/spring-webmvc-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-expression/5.2.5.RELEASE/spring-expression-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-aop/2.2.6.RELEASE/spring-boot-starter-aop-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-aop/5.2.5.RELEASE/spring-aop-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/aspectj/aspectjweaver/1.9.5/aspectjweaver-1.9.5.jar, file:/D:/Apache/repository/org/springframework/spring-context-support/5.2.5.RELEASE/spring-context-support-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-beans/5.2.5.RELEASE/spring-beans-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-context/5.2.5.RELEASE/spring-context-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-data-redis/2.2.6.RELEASE/spring-boot-starter-data-redis-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/data/spring-data-redis/2.2.6.RELEASE/spring-data-redis-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/data/spring-data-keyvalue/2.2.6.RELEASE/spring-data-keyvalue-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/data/spring-data-commons/2.2.6.RELEASE/spring-data-commons-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-tx/5.2.5.RELEASE/spring-tx-5.2.5.RELEASE.jar, file:/D:/Apache/repository/org/springframework/spring-oxm/5.2.5.RELEASE/spring-oxm-5.2.5.RELEASE.jar, file:/D:/Apache/repository/io/lettuce/lettuce-core/5.2.2.RELEASE/lettuce-core-5.2.2.RELEASE.jar, file:/D:/Apache/repository/io/netty/netty-common/4.1.48.Final/netty-common-4.1.48.Final.jar, file:/D:/Apache/repository/io/netty/netty-handler/4.1.48.Final/netty-handler-4.1.48.Final.jar, file:/D:/Apache/repository/io/netty/netty-resolver/4.1.48.Final/netty-resolver-4.1.48.Final.jar, file:/D:/Apache/repository/io/netty/netty-buffer/4.1.48.Final/netty-buffer-4.1.48.Final.jar, file:/D:/Apache/repository/io/netty/netty-codec/4.1.48.Final/netty-codec-4.1.48.Final.jar, file:/D:/Apache/repository/io/netty/netty-transport/4.1.48.Final/netty-transport-4.1.48.Final.jar, file:/D:/Apache/repository/io/projectreactor/reactor-core/3.3.4.RELEASE/reactor-core-3.3.4.RELEASE.jar, file:/D:/Apache/repository/org/reactivestreams/reactive-streams/1.0.3/reactive-streams-1.0.3.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-configuration-processor/2.2.6.RELEASE/spring-boot-configuration-processor-2.2.6.RELEASE.jar, file:/D:/Apache/repository/com/baomidou/mybatis-plus-boot-starter/3.3.1/mybatis-plus-boot-starter-3.3.1.jar, file:/D:/Apache/repository/com/baomidou/mybatis-plus/3.3.1/mybatis-plus-3.3.1.jar, file:/D:/Apache/repository/com/baomidou/mybatis-plus-extension/3.3.1/mybatis-plus-extension-3.3.1.jar, file:/D:/Apache/repository/com/baomidou/mybatis-plus-core/3.3.1/mybatis-plus-core-3.3.1.jar, file:/D:/Apache/repository/com/baomidou/mybatis-plus-annotation/3.3.1/mybatis-plus-annotation-3.3.1.jar, file:/D:/Apache/repository/com/github/jsqlparser/jsqlparser/3.1/jsqlparser-3.1.jar, file:/D:/Apache/repository/org/mybatis/mybatis/3.5.3/mybatis-3.5.3.jar, file:/D:/Apache/repository/org/mybatis/mybatis-spring/2.0.3/mybatis-spring-2.0.3.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-autoconfigure/2.2.6.RELEASE/spring-boot-autoconfigure-2.2.6.RELEASE.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot-starter-jdbc/2.2.6.RELEASE/spring-boot-starter-jdbc-2.2.6.RELEASE.jar, file:/D:/Apache/repository/com/zaxxer/HikariCP/3.4.2/HikariCP-3.4.2.jar, file:/D:/Apache/repository/org/springframework/spring-jdbc/5.2.5.RELEASE/spring-jdbc-5.2.5.RELEASE.jar, file:/D:/Apache/repository/mysql/mysql-connector-java/8.0.17/mysql-connector-java-8.0.17.jar, file:/D:/Apache/repository/com/oracle/ojdbc6/11.2.0.3/ojdbc6-11.2.0.3.jar, file:/D:/Apache/repository/com/microsoft/sqlserver/sqljdbc4/4.0/sqljdbc4-4.0.jar, file:/D:/Apache/repository/org/postgresql/postgresql/42.2.11/postgresql-42.2.11.jar, file:/D:/Apache/repository/com/alibaba/druid-spring-boot-starter/1.1.13/druid-spring-boot-starter-1.1.13.jar, file:/D:/Apache/repository/com/alibaba/druid/1.1.13/druid-1.1.13.jar, file:/D:/Apache/repository/org/slf4j/slf4j-api/1.7.30/slf4j-api-1.7.30.jar, file:/D:/Apache/repository/org/quartz-scheduler/quartz/2.3.0/quartz-2.3.0.jar, file:/D:/Apache/repository/com/mchange/mchange-commons-java/0.2.11/mchange-commons-java-0.2.11.jar, file:/D:/Apache/repository/commons-lang/commons-lang/2.6/commons-lang-2.6.jar, file:/D:/Apache/repository/commons-fileupload/commons-fileupload/1.2.2/commons-fileupload-1.2.2.jar, file:/D:/Apache/repository/commons-io/commons-io/2.5/commons-io-2.5.jar, file:/D:/Apache/repository/commons-codec/commons-codec/1.10/commons-codec-1.10.jar, file:/D:/Apache/repository/commons-configuration/commons-configuration/1.10/commons-configuration-1.10.jar, file:/D:/Apache/repository/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-core/1.4.0/shiro-core-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-lang/1.4.0/shiro-lang-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-cache/1.4.0/shiro-cache-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-crypto-hash/1.4.0/shiro-crypto-hash-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-crypto-core/1.4.0/shiro-crypto-core-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-crypto-cipher/1.4.0/shiro-crypto-cipher-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-config-core/1.4.0/shiro-config-core-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-config-ogdl/1.4.0/shiro-config-ogdl-1.4.0.jar, file:/D:/Apache/repository/commons-beanutils/commons-beanutils/1.9.3/commons-beanutils-1.9.3.jar, file:/D:/Apache/repository/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-event/1.4.0/shiro-event-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-spring/1.4.0/shiro-spring-1.4.0.jar, file:/D:/Apache/repository/org/apache/shiro/shiro-web/1.4.0/shiro-web-1.4.0.jar, file:/D:/Apache/repository/io/jsonwebtoken/jjwt/0.7.0/jjwt-0.7.0.jar, file:/D:/Apache/repository/com/fasterxml/jackson/core/jackson-databind/2.10.3/jackson-databind-2.10.3.jar, file:/D:/Apache/repository/com/fasterxml/jackson/core/jackson-annotations/2.10.3/jackson-annotations-2.10.3.jar, file:/D:/Apache/repository/com/fasterxml/jackson/core/jackson-core/2.10.3/jackson-core-2.10.3.jar, file:/D:/Apache/repository/com/github/axet/kaptcha/0.0.9/kaptcha-0.0.9.jar, file:/D:/Apache/repository/com/jhlabs/filters/2.0.235/filters-2.0.235.jar, file:/D:/Apache/repository/io/springfox/springfox-swagger2/2.7.0/springfox-swagger2-2.7.0.jar, file:/D:/Apache/repository/io/swagger/swagger-annotations/1.5.13/swagger-annotations-1.5.13.jar, file:/D:/Apache/repository/io/swagger/swagger-models/1.5.13/swagger-models-1.5.13.jar, file:/D:/Apache/repository/io/springfox/springfox-spi/2.7.0/springfox-spi-2.7.0.jar, file:/D:/Apache/repository/io/springfox/springfox-core/2.7.0/springfox-core-2.7.0.jar, file:/D:/Apache/repository/io/springfox/springfox-schema/2.7.0/springfox-schema-2.7.0.jar, file:/D:/Apache/repository/io/springfox/springfox-swagger-common/2.7.0/springfox-swagger-common-2.7.0.jar, file:/D:/Apache/repository/io/springfox/springfox-spring-web/2.7.0/springfox-spring-web-2.7.0.jar, file:/D:/Apache/repository/org/reflections/reflections/0.9.11/reflections-0.9.11.jar, file:/D:/Apache/repository/org/javassist/javassist/3.21.0-GA/javassist-3.21.0-GA.jar, file:/D:/Apache/repository/com/google/guava/guava/18.0/guava-18.0.jar, file:/D:/Apache/repository/com/fasterxml/classmate/1.5.1/classmate-1.5.1.jar, file:/D:/Apache/repository/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE.jar, file:/D:/Apache/repository/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE.jar, file:/D:/Apache/repository/org/mapstruct/mapstruct/1.1.0.Final/mapstruct-1.1.0.Final.jar, file:/D:/Apache/repository/io/springfox/springfox-swagger-ui/2.7.0/springfox-swagger-ui-2.7.0.jar, file:/D:/Apache/repository/com/qiniu/qiniu-java-sdk/7.2.23/qiniu-java-sdk-7.2.23.jar, file:/D:/Apache/repository/com/squareup/okhttp3/okhttp/3.14.7/okhttp-3.14.7.jar, file:/D:/Apache/repository/com/squareup/okio/okio/1.17.2/okio-1.17.2.jar, file:/D:/Apache/repository/com/aliyun/oss/aliyun-sdk-oss/2.8.3/aliyun-sdk-oss-2.8.3.jar, file:/D:/Apache/repository/org/apache/httpcomponents/httpclient/4.5.12/httpclient-4.5.12.jar, file:/D:/Apache/repository/org/jdom/jdom/1.1/jdom-1.1.jar, file:/D:/Apache/repository/com/qcloud/cos_api/4.4/cos_api-4.4.jar, file:/D:/Apache/repository/org/apache/httpcomponents/httpcore/4.4.13/httpcore-4.4.13.jar, file:/D:/Apache/repository/org/apache/httpcomponents/httpmime/4.5.12/httpmime-4.5.12.jar, file:/D:/Apache/repository/org/json/json/20140107/json-20140107.jar, file:/D:/Apache/repository/junit/junit/4.12/junit-4.12.jar, file:/D:/Apache/repository/org/hamcrest/hamcrest-core/2.1/hamcrest-core-2.1.jar, file:/D:/Apache/repository/joda-time/joda-time/2.9.9/joda-time-2.9.9.jar, file:/D:/Apache/repository/com/google/code/gson/gson/2.8.5/gson-2.8.5.jar, file:/D:/Apache/repository/com/alibaba/fastjson/1.2.72/fastjson-1.2.72.jar, file:/D:/Apache/repository/cn/hutool/hutool-all/4.1.1/hutool-all-4.1.1.jar, file:/D:/Apache/repository/org/projectlombok/lombok/1.18.4/lombok-1.18.4.jar, file:/D:/Apache/repository/org/springframework/boot/spring-boot/2.3.4.RELEASE/spring-boot-2.3.4.RELEASE.jar, file:/D:/IDEA2019.3/IntelliJ%20IDEA%202019.3.2/lib/idea_rt.jar]
07:17:05.510 [main] ERROR org.springframework.boot.SpringApplication - Application run failed
java.lang.NoSuchMethodError: org.yaml.snakeyaml.LoaderOptions.setMaxAliasesForCollections(I)V
	at org.springframework.boot.env.OriginTrackedYamlLoader.createYaml(OriginTrackedYamlLoader.java:67)
	at org.springframework.beans.factory.config.YamlProcessor.process(YamlProcessor.java:132)
	at org.springframework.boot.env.OriginTrackedYamlLoader.load(OriginTrackedYamlLoader.java:82)
	at org.springframework.boot.env.YamlPropertySourceLoader.load(YamlPropertySourceLoader.java:50)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.loadDocuments(ConfigFileApplicationListener.java:607)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.load(ConfigFileApplicationListener.java:523)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.loadForFileExtension(ConfigFileApplicationListener.java:498)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.load(ConfigFileApplicationListener.java:468)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.lambda$null$7(ConfigFileApplicationListener.java:447)
	at java.lang.Iterable.forEach(Iterable.java:75)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.lambda$load$8(ConfigFileApplicationListener.java:447)
	at java.lang.Iterable.forEach(Iterable.java:75)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.load(ConfigFileApplicationListener.java:444)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.lambda$load$0(ConfigFileApplicationListener.java:347)
	at org.springframework.boot.context.config.FilteredPropertySource.apply(FilteredPropertySource.java:54)
	at org.springframework.boot.context.config.ConfigFileApplicationListener$Loader.load(ConfigFileApplicationListener.java:335)
	at org.springframework.boot.context.config.ConfigFileApplicationListener.addPropertySources(ConfigFileApplicationListener.java:226)
	at org.springframework.boot.context.config.ConfigFileApplicationListener.postProcessEnvironment(ConfigFileApplicationListener.java:210)
	at org.springframework.boot.context.config.ConfigFileApplicationListener.onApplicationEnvironmentPreparedEvent(ConfigFileApplicationListener.java:200)
	at org.springframework.boot.context.config.ConfigFileApplicationListener.onApplicationEvent(ConfigFileApplicationListener.java:188)
	at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172)
	at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165)
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139)
	at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:127)
	at org.springframework.boot.context.event.EventPublishingRunListener.environmentPrepared(EventPublishingRunListener.java:80)
	at org.springframework.boot.SpringApplicationRunListeners.environmentPrepared(SpringApplicationRunListeners.java:53)
	at org.springframework.boot.SpringApplication.prepareEnvironment(SpringApplication.java:345)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:308)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1237)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)
	at io.renren.RenrenApplication.main(RenrenApplication.java:19)

Process finished with exit code 1

出现这个问题的原因大部分是忘记添加如下的maven依赖,

        < dependency>
		    <groupId>org.yaml</groupId>
			<artifactId>snakeyaml</artifactId>
			<version>1.25</version>
		</dependency>

当然,我添加了依赖,但却还是报这个错,找了好久也没找到问题所在,最后在一位大佬的指点下找到了问题所在,是由于父项目和子项目的snakeyaml版本与项目的版本不一致导致的。如何查找项目的版本呢?我的错误是java.lang.NoSuchMethodError: org.yaml.snakeyaml.LoaderOptions.setMaxAliasesForCollections(I)V这个,我就首先想到了用全局查找找一下我的项目中setMaxAliasesForCollections的版本等一些方面(我用的是IDEA,全局查找的方式是Ctrl+N,eclipse的话应该是Ctrl+H,别的编辑器就不太清楚了,可以自行BD一下),如图所示:

ps:请注意,上图有5个范围,最好是都查找一下,防止遗漏!!!
我检查了自己的版本,是1.25,和这个的版本不一致,因此导致了上述的错误,改一下版本就好了!

;