In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article "springboot configuration redis project startup errors how to solve" most people do not understand, so the editor summed up the following content, detailed, clear steps, with a certain reference value, I hope you can read this article can be rewarded, let's take a look at this "springboot configuration redis project startup errors how to solve" article it.
Error when springboot configures redis project startup
When I first started learning redis, I followed the online tutorials to integrate redis and jedis into spring boot. After the integration, the startup project always failed.
The following mistakes are always exposed
Correct the classpath of your application so that it contains a single, compatible version of org.springframework.data.repository.config.RepositoryConfigurationSource
* *
APPLICATION FAILED TO START
* *
Description:
An attempt was made to call the method org.springframework.data.repository.config.RepositoryConfigurationSource.getAttribute (Ljava/lang/String;) Ljava/lang/String; but it does not exist. Its class, org.springframework.data.repository.config.RepositoryConfigurationSource, is available from the following locations:
JarJR fileDrexD2repositoryUnix orgUnix repositoryUniverse dataUniverse SpringframedataUniverse CommonsUniverse 2.0.10.RELEASEGER. JarThink orgplash springframeworkCharger repositoryconfigandRepositoryConfigurationSource.class
It was loaded from the following location:
File:/D:/m2/repository/org/springframework/data/spring-data-commons/2.0.10.RELEASE/spring-data-commons-2.0.10.RELEASE.jar
Action:
Correct the classpath of your application so that it contains a single, compatible version of org.springframework.data.repository.config.RepositoryConfigurationSource
2018-11-22 13 ConfigServletWebServerApplicationContext 03 INFO 2196-[main] ConfigServletWebServerApplicationContext: Closing org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@1a451d4d: startup date [Thu Nov 22 13:03:50 CST 2018]; root of context hierarchy
Process finished with exit code 1
Then I searched the Internet for a long time, but there was no solution to this error. I came across a blog that also had a type error when starting the project, which was also a jar package conflict, and then the blogger solved it by changing the version numbers of redis and jedis. I also changed the version numbers to the same as that blogger, but there was still the same error after startup.
Later, I thought that if I removed all the version numbers and asked "spring-boot-starter-parent" to automatically provide us with the corresponding version of the jar package, so that I could avoid some unexpected conflicts when I specified the version number. So I removed the version numbers of redis and jedis, and sure enough, the project started normally.
What a strange error..
Solve the problem of ERR Client sent AUTH and but no password is set when redis reports errors at the start of springboot project
First of all, take a look at the part of my springboot configuring redis as shown in the figure:
It is obvious that the startup password of redis is 123456.
The local redis version is 3.0.1. The password for requirepass content in the redis.windows.conf file is also changed to 123456. Here, when removing the # in front of requirepass, be sure to remove one more space, otherwise an error will be reported:
Invalid argument during startup: unknown conf file parameter: requirepass
At this point, the redis password is the same as that of springboot, and the next step is to start redis and then start springboot.
The way we start is to go to the redis installation directory, execute redis-server.exe, and then start normally. However, after starting springboot, an error occurred when calling redis, as shown in the figure:
At first, I thought that the version of 2.9.0 redis dependency introduced in my Pom.xml file was not compatible, but the 2.9.0 installation package of Redis was not available on the Internet. Half a day was wasted.
Later, I found out that this error told me that I did not set a password. The reason is that the method at startup is wrong.
Be sure to remember to start the local redis. If you set the password, remember to bring the configuration file with you. The startup command is as follows:
Redis-server.exe redis.windows.conf above is about "springboot configuration redis project startup errors how to solve" this article, I believe we all have a certain understanding, I hope the editor to share the content to help you, if you want to know more related knowledge, please pay attention to the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.