spring + redis 整合报类找不到异常 [问题点数:40分,结帖人meiwenhui]

一键查看最优答案

确认一键查看最优答案?
本功能为VIP专享,开通VIP获取答案速率将提升10倍哦!
Bbs2
本版专家分:162
结帖率 100%
Bbs4
本版专家分:1163
Bbs2
本版专家分:162
SpringBoot 引入Jedis 错:NoClassDefFoundError: redis/clients/util/SafeEncoder
错误详情: Caused by: java.lang.NoClassDefFoundError: <em>redis</em>/clients/util/SafeEncoder at org.<em>spring</em>framework.data.<em>redis</em>.connection.jedis.JedisConverters.lambda$static$1(JedisConverters.java:127) ~[<em>spring</em>-d...
Caused by: java.lang.NoClassDefFoundError: redis/clients/util/Pool
严重: Exception sending context initialized event to listener instance of class org.<em>spring</em>framework.web.context.ContextLoaderListener org.<em>spring</em>framework.beans.factory.BeanCreationException: Error cre...
redis序列化org.springframework.data.redis.serializer.SerializationException
有没有遇到这样错误的大神,求支持~ [ ERROR] [2019-06-26 11:26:01] org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/login-service].[dispatcherServlet] [175] - Servlet.service() for servlet [dispatcherServlet] in context with path [/login-service] threw exception org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Could not read JSON: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]); nested exception is com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:75) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashValue(AbstractOperations.java:354) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashMap(AbstractOperations.java:298) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultHashOperations.entries(DefaultHashOperations.java:247) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultBoundHashOperations.entries(DefaultBoundHashOperations.java:183) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.getSession(RedisOperationsSessionRepository.java:466) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:435) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:247) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getRequestedSession(SessionRepositoryFilter.java:380) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:306) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:201) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetails.(WebAuthenticationDetails.java:53) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:42) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:30) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.createAuthentication(AnonymousAuthenticationFilter.java:117) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:97) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.oauth2.provider.authentication.OAuth2AuthenticationProcessingFilter.doFilter(OAuth2AuthenticationProcessingFilter.java:176) ~[<em>spring</em>-security-oauth2-2.3.5.RELEASE.jar:?] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:74) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:357) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:270) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:92) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:93) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter.doFilterInternal(SessionRepositoryFilter.java:151) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.filterAndRecordMetrics(WebMvcMetricsFilter.java:117) ~[<em>spring</em>-boot-actuator-2.1.3.RELEASE.jar:2.1.3.RELEASE] at org.<em>spring</em>framework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.doFilterInternal(WebMvcMetricsFilter.java:106) ~[<em>spring</em>-boot-actuator-2.1.3.RELEASE.jar:2.1.3.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at com.alibaba.csp.sentinel.adapter.servlet.CommonFilter.doFilter(CommonFilter.java:89) ~[sentinel-web-servlet-1.5.2.jar:?] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:200) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardContextValve.__invoke(StandardContextValve.java:96) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:41002) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:834) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_91] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_91] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91] Caused by: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:67) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.reportBadDefinition(DeserializationContext.java:1452) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.handleMissingInstantiator(DeserializationContext.java:1028) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:348) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:29) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromObject(AsArrayTypeDeserializer.java:61) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserializeWithType(AbstractDeserializer.java:254) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.FieldProperty.deserializeAndSet(FieldProperty.java:145) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:288) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:151) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromAny(AsArrayTypeDeserializer.java:71) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.UntypedObjectDeserializer$Vanilla.deserializeWithType(UntypedObjectDeserializer.java:712) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.TypeWrappedDeserializer.deserialize(TypeWrappedDeserializer.java:68) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4013) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3129) ~[jackson-databind-2.9.8.jar:2.9.8] at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:73) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] ... 86 more [ ERROR] [2019-06-26 11:26:01] org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/login-service].[dispatcherServlet] [175] - Servlet.service() for servlet [dispatcherServlet] threw exception org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Could not read JSON: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]); nested exception is com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:75) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashValue(AbstractOperations.java:354) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashMap(AbstractOperations.java:298) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultHashOperations.entries(DefaultHashOperations.java:247) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultBoundHashOperations.entries(DefaultBoundHashOperations.java:183) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.getSession(RedisOperationsSessionRepository.java:466) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:435) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:247) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getRequestedSession(SessionRepositoryFilter.java:380) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:306) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:201) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetails.(WebAuthenticationDetails.java:53) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:42) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:30) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.createAuthentication(AnonymousAuthenticationFilter.java:117) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:97) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.oauth2.provider.authentication.OAuth2AuthenticationProcessingFilter.doFilter(OAuth2AuthenticationProcessingFilter.java:176) ~[<em>spring</em>-security-oauth2-2.3.5.RELEASE.jar:?] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:357) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:270) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter.doFilterInternal(SessionRepositoryFilter.java:151) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:461) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:384) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:394) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:253) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.throwable(StandardHostValve.java:348) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:173) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:834) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_91] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_91] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91] Caused by: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:67) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.reportBadDefinition(DeserializationContext.java:1452) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.handleMissingInstantiator(DeserializationContext.java:1028) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:348) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:29) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromObject(AsArrayTypeDeserializer.java:61) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserializeWithType(AbstractDeserializer.java:254) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.FieldProperty.deserializeAndSet(FieldProperty.java:145) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:288) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:151) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromAny(AsArrayTypeDeserializer.java:71) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.UntypedObjectDeserializer$Vanilla.deserializeWithType(UntypedObjectDeserializer.java:712) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.TypeWrappedDeserializer.deserialize(TypeWrappedDeserializer.java:68) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4013) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3129) ~[jackson-databind-2.9.8.jar:2.9.8] at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:73) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] ... 62 more [ ERROR] [2019-06-26 11:26:01] org.apache.catalina.core.ContainerBase.[Tomcat].[localhost] [175] - Exception Processing ErrorPage[errorCode=0, location=/error] org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Could not read JSON: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]); nested exception is com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:75) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashValue(AbstractOperations.java:354) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.AbstractOperations.deserializeHashMap(AbstractOperations.java:298) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultHashOperations.entries(DefaultHashOperations.java:247) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.data.<em>redis</em>.core.DefaultBoundHashOperations.entries(DefaultBoundHashOperations.java:183) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.getSession(RedisOperationsSessionRepository.java:466) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:435) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.data.<em>redis</em>.RedisOperationsSessionRepository.findById(RedisOperationsSessionRepository.java:247) ~[<em>spring</em>-session-data-<em>redis</em>-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getRequestedSession(SessionRepositoryFilter.java:380) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:306) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter$SessionRepositoryRequestWrapper.getSession(SessionRepositoryFilter.java:201) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at javax.servlet.http.HttpServletRequestWrapper.getSession(HttpServletRequestWrapper.java:241) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetails.(WebAuthenticationDetails.java:53) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:42) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.WebAuthenticationDetailsSource.buildDetails(WebAuthenticationDetailsSource.java:30) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.createAuthentication(AnonymousAuthenticationFilter.java:117) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:97) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.oauth2.provider.authentication.OAuth2AuthenticationProcessingFilter.doFilter(OAuth2AuthenticationProcessingFilter.java:176) ~[<em>spring</em>-security-oauth2-2.3.5.RELEASE.jar:?] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:101) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178) ~[<em>spring</em>-security-web-5.1.4.RELEASE.jar:5.1.4.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:357) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.<em>spring</em>framework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:270) ~[<em>spring</em>-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.<em>spring</em>framework.session.web.http.SessionRepositoryFilter.doFilterInternal(SessionRepositoryFilter.java:151) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.<em>spring</em>framework.session.web.http.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) ~[<em>spring</em>-session-core-2.1.4.RELEASE.jar:2.1.4.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:461) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:384) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:394) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:253) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.throwable(StandardHostValve.java:348) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:173) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:834) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_91] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_91] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91] Caused by: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Cannot construct instance of `com.sun.proxy.$Proxy224` (no Creators, like default construct, exist): no default constructor found at [Source: (byte[])"["org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext",{"accessToken":null,"accessTokenRequest":["com.sun.proxy.$Proxy224",{}],"state":["java.util.HashMap",{}]}]"; line: 1, column: 142] (through reference chain: org.<em>spring</em>framework.security.oauth2.client.DefaultOAuth2ClientContext["accessTokenRequest"]) at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:67) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.reportBadDefinition(DeserializationContext.java:1452) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.DeserializationContext.handleMissingInstantiator(DeserializationContext.java:1028) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:348) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.MapDeserializer.deserialize(MapDeserializer.java:29) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromObject(AsArrayTypeDeserializer.java:61) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.AbstractDeserializer.deserializeWithType(AbstractDeserializer.java:254) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.FieldProperty.deserializeAndSet(FieldProperty.java:145) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:288) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:151) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer._deserialize(AsArrayTypeDeserializer.java:116) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.jsontype.impl.AsArrayTypeDeserializer.deserializeTypedFromAny(AsArrayTypeDeserializer.java:71) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.std.UntypedObjectDeserializer$Vanilla.deserializeWithType(UntypedObjectDeserializer.java:712) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.deser.impl.TypeWrappedDeserializer.deserialize(TypeWrappedDeserializer.java:68) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(ObjectMapper.java:4013) ~[jackson-databind-2.9.8.jar:2.9.8] at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:3129) ~[jackson-databind-2.9.8.jar:2.9.8] at org.<em>spring</em>framework.data.<em>redis</em>.serializer.Jackson2JsonRedisSerializer.deserialize(Jackson2JsonRedisSerializer.java:73) ~[<em>spring</em>-data-<em>redis</em>-2.1.5.RELEASE.jar:2.1.5.RELEASE] ... 62 more [ INFO ] [2019-06-26 11:30:56] com.netflix.discovery.shared.resolver.aws.ConfigClusterResolver [43] - Resolving eureka endpoints via configuration
问题已解决 Caused by: java.lang.ClassNotFoundException: redis.clients.jedis.JedisPoolConfig
<em>spring</em>boot中使用<em>spring</em>-data-<em>redis</em>出现Caused by: java.lang.ClassNotFoundException: <em>redis</em>.clients.jedis.JedisPoolConfig 在maven的配置如下: &lt;dependency&gt; &lt;groupId&gt;org.<em>spring</em>framework.boot&lt;/gr...
java.lang.NoClassDefFoundError: redis/clients/util/IOUtils
启动项目的时候<em>报</em><em>找</em><em>不到</em>这个<em>类</em>的错,项目中确实存在这个<em>类</em>(在jar包中存在),项目启动是运行的编译路径中的class,所以在编译目录下查看是否有该<em>类</em>,如果没有说明编译路径中没有该class,则没有将该class添加到编译路径中 项目运行,先编译源码,将源码编译到编译路径中,然后将编译路径中的内容copy到war包中,然后启动项目!!! ...
org.springframework.data.redis.serializer.SerializationException: Could not read JSON
org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Could not read JSON: failed to lazily initialize a collection, could not initialize proxy - no Session (through reference chain: com.o...
错误 'org.springframework.data.redis.connection.RedisConnectionFactory' that could not be found.
  Parameter 0 of method stringRedisTemplate in org.<em>spring</em>framework.boot.autoconfigure.data.<em>redis</em>.RedisAutoConfiguration required a bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConne...
jedisConnectionFactory: NoClassDefFoundError: redis/clients/util/Pool
在做<em>spring</em>boot 2.x + <em>redis</em>(采用jedis)<em>整合</em>,启动时 JedisConnectionFactory factory = new JedisConnectionFactory(); 抛出<em>异常</em>:Factory method 'jedisConnectionFactory' threw exception; nested exception is java.lan...
spring redis jedis 出现java.lang.ClassNotFoundException: redis.clients.jedis.JedisPoolConfig
这个问题百度了好多 有出现的 但是都没有解决明明有jedis-2.9.0.jar 偏偏就是提示java.lang.ClassNotFoundException: <em>redis</em>.clients.jedis.JedisPoolConfig其实解决方法很简单 导入commons-pool2-2.5.0.jar就可以了   原本我以为只有commons-pool-1.5.4.jar就可以了。...
SpringBoot2.0: Caused by: java.lang.NoClassDefFoundError: redis/clients/jedis/JedisPoolConfig
学习SpringBoot2.0过程中,使用Redis时可能会遇到这个问题。主要原因是jar包的问题。 配置文件pom.xml一般是这样的: &lt;dependency&gt; &lt;groupId&gt;org.<em>spring</em>framework.boot&lt;/groupId&gt; &lt;artifactId&gt;<em>spring</em>-boot-starter-data...
Could not autowire. No beans of 'RedisConnectionFactory' type found
RedisConnectionFactory factory 提示错误 @Configuration public class RedisConfig { @Bean public RedisTemp
springboot data.redis.RedisConnectionFactory 集成问题
<em>spring</em>boot 集成<em>spring</em>boot data <em>redis</em>出错: org.<em>spring</em>framework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConnectionFactory' a...
SpringBoot和redis集成的时候,错误记录
SpringBoot和<em>redis</em>集成的时候,CachingConfigurerSupport 的子<em>类</em>RedisConfig中,RedisConnectionFactory factory<em>报</em>错:Could not autowire. No beans of 'RedisConnectionFactory' type found. less... (Ctrl+F1) Checks autowiring
redis + Jedis + Spring错Type 'redis/clients/jedis/JedisPoolConfig'(current frame, stack[4]) is not a
<em>redis</em> + Jedis + Spring集成之后运行<em>报</em>以下错误: log4j:WARNNo appenders could be found for logger(org.<em>spring</em>framework.core.env.StandardEnvironment). log4j:WARNPlease initialize the log4j system properly. SLF4J:Failed to load class "org.slf4j.impl.StaticLoggerBinder". SL
nested exception is java.lang.ClassNotFoundException: redis.clients.jedis.JedisP
70882_439329.png]
Redis客户端Jedis 项目错 java.lang.ClassNotFoundException: redis.clients.jedis.Jedis
【更多资讯及资料获取,关注微信公众号号:浅醉JAVA】 问题描述描述: 在maven项目中,使用Redis客户端的客户端Jedis连接测试。<em>报</em>错:java.lang.ClassNotFoundException: <em>redis</em>.clients.jedis.Jedis Exception in thread "main" java.lang.NoClassDefFoundError: redi...
IntelliJ Idea错Could not autowire. No beans of 'xxxx' type found的错误提示,并且编译运行时错解决方案
在使用<em>spring</em>boot<em>整合</em>mybatis的时候,在控制器中使用自动注入来注入一个mapper出现了Could not autowire. No beans of 'xxxx' type found<em>报</em>错,提示不能够自动注入bean。其实该问题如果编译运行程序不<em>报</em>错正常运行的话那么可能只是intellij idea的问题,如果不能够正常的编译运行,则可能是<em>spring</em> auto scan配置,在编...
SpringBoot 引入Jedis 错:java.lang.ClassNotFoundException: redis.clients.util.SafeEncoder
参考:https://blog.csdn.net/taotao_guiwang/article/details/102519951 参考:https://blog.csdn.net/doubleqinyan/article/details/102688467 运行提示<em>报</em>错 Caused by: java.lang.NoClassDefFoundError: <em>redis</em>/clients...
web应用集成jedis错java.lang.NoClassDefFoundError
最近搞了一个项目需要使用<em>redis</em>,但是使用过程中各种错,希望各位帮忙指点一下。 因为是java web项目,所以选用jedis 先描述一下背景:现有的框架用<em>spring</em>mvc,集成了mybatis,
org.springframework.data.redis.serializer.SerializationException: Cannot deserialize
<em>redis</em> 反序列化错误 **当创建项目使用<em>redis</em>缓存时 <em>报</em>了“org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Cannot deserialize;”这样的错误 如下面代码片段 org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: ...
java.lang.NoClassDefFoundError: redis/clients/jedis/exceptions/JedisDataException
1、错误描述java.lang.IllegalStateException at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1743) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(Web
Java集成Redis
严重: Context initialization failed org.<em>spring</em>framework.beans.factory.CannotLoadBeanClassException: Er
spring boot注入jar包中的接口总是提示that could not be found
首先是在<em>spring</em> boot项目中注入的jar包中的接口 ``` @Controller public class MessageTransferStationController { @Autowired private MessageClient messageClient; } ``` 其次,jar包中的MessageClient的源码 ``` public interface MessageClient { } ``` MessageClient分别有三个实现<em>类</em> ``` public class CoreMessageClient implements MessageClient {} @Component public class SpringMessageClientImpl extends CoreMessageClient implements MessageClient {} public class Spring2MessageClientImpl extends CoreMessageClient implements MessageClient {} ``` 当我在<em>spring</em> boot项目中注入MessageClient接口的时候,启动<em>报</em>错: 017-06-12 15:06:53.281 WARN 9780 --- [ main] ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.<em>spring</em>framework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'messageTransferStationController': Unsatisfied dependency expressed through field 'messageClient'; nested exception is org.<em>spring</em>framework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.sinosoft.messageclient.MessageClient' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.<em>spring</em>framework.beans.factory.annotation.Autowired(required=true)} 2017-06-12 15:06:53.283 INFO 9780 --- [ main] o.apache.catalina.core.StandardService : Stopping service Tomcat 2017-06-12 15:06:53.316 INFO 9780 --- [ main] utoConfigurationReportLoggingInitializer : Error starting ApplicationContext. To display the auto-configuration report re-run your application with 'debug' enabled. 2017-06-12 15:06:53.431 ERROR 9780 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter : *************************** APPLICATION FAILED TO START *************************** Description: Field messageClient in com.sinosoft.oa.message_transfer_station.web.MessageTransferStationController required a bean of type 'com.sinosoft.messageclient.MessageClient' that could not be found. Action: Consider defining a bean of type 'com.sinosoft.messageclient.MessageClient' in your configuration. Process finished with exit code 1 --- 请问各位大佬,为什么MessageClient为什么不能注入,我猜想过MessageClient的实现<em>类</em>没有被Spring管理,我看了jar包中源码有一个实现<em>类</em>加上了@Component注解 求教各位大佬,这是什么原因引起的? 注:引用jar包中的其它接口也测试过了,同样的错误,也就是说引用的这个jar包中的所有接口都没有被<em>spring</em>管理,或者没有扫描。
SpringBoot整合redis启动错'org.springframework.data.redis.connection.RedisConnectionF
SpringBoot版本为1.5.7 Pom.xml: org.<em>spring</em>framework.boot <
Java错笔记-org.springframework.data.redis.serializer.SerializationException: Could not read JSON
错误场景:将对象(实体)存到<em>redis</em>,取值时<em>报</em>错; 由于对象(实体)中缺少json的某个字段属性引起; 解决方式对象(实体)加<em>类</em>注解 @JsonIgnoreProperties(ignoreUnknown = true) ...
redis数据库连接时遇到的错误:redis.clients.jedis.exceptions.JedisConnectionException: java.net.ConnectException:
测试是否能连接<em>redis</em>,代码如下:Jedis jedis = new Jedis(&quot;192.168.106.128&quot;,6379); System.out.println(jedis.ping()); jedis.close();问题描述:问题解决:1)打开端口6379(sudo ufw allow 6379)2)关闭防火墙.(可能linux防火墙作用,限制了端口的出入)3)修改<em>redis</em>.con...
Web项目中引入Redis引发的错误信息
<em>报</em>错信息 Illegal access: this web application instance has been stopped already. Could not load <em>redis</em>.clients.util.IOUtils. The eventual following stack trace is caused by an error thrown for debugging...
已解决 java.lang.NoClassDefFoundError: org/springframework/util/ClassUtils
java.lang.NoClassDefFoundError: org/<em>spring</em>framework/util/ClassUtils at org.<em>spring</em>framework.test.context.junit4.SpringJUnit4ClassRunner.&amp;lt;clinit&amp;gt;(SpringJUnit4ClassRunner.java:101) at sun.reflect...
springboot+mybatis出现A component required a bean of type 'XXX' that could not be found错误解决
当你在使用<em>spring</em>boot+mybatis的时候发现以下图片中的错误 问题很简单该接口没有受到<em>spring</em>的管理 ,   首先我们来查看你的dao接口,看看你是不是被网上那些千篇一律的写法给迷惑了 在这里你应该写一个@Mapper的注解 @Mapper注解的的作用 1:为了把mapper这个DAO交給Spring管理 2:为了不再写mapper映射文件 3:为了给mapper接...
java.lang.NoClassDefFoundError 问题求解答
自己做的小程序,引用百度地图的时候 出现的<em>异常</em>,我另外有个项目是导入的项目,里面也是有百度的SDK引用,同样的eclipse和ADT的版本,没有出现这个<em>异常</em>,试了网上的很多办法,没有能解决。求大神指教!
SpringBoot 整合Redis错:NoClassDefFoundError: redis/clients/util/SafeEncoder
QUESTION:SpringBoot <em>整合</em>Redis<em>报</em>错:NoClassDefFoundError: <em>redis</em>/clients/util/SafeEncoder? ANSWER: 这种情况是版本不兼容,可以考虑更换<em>redis</em>版本: &lt;dependency&gt; &lt;groupId&gt;<em>redis</em>.clients&lt;/groupId&gt; &lt;artif...
spring4集成redis错java.lang.ClassNotFoundException: org.apache.commons.pool.impl.GenericObjectPool$Con
多引用几个JAR包 jedis-2.1.0.jar <em>spring</em>-data-<em>redis</em>-1.0.2.RELEASE.jar 只引入这两个的话,估计也会<em>报</em>上面的那个错,所以下面的两个也要引入 commons-pool-1.5.5.jar commons-pool2-2.2.jar 点击打开链接
使用redis整合spring时出现java.lang.NoClassDefFoundError
可能原因排查: <em>redis</em>组合<em>spring</em>时的jar包不合理,可以参考maven 仓库给出的对应版本jedis的maven仓库地址, 如<em>spring</em> Data Redis <em>整合</em> 2.可能是服务器网络不通,或者在解析外部域名时无法解析,比如对接第三方接口时dns解析<em>异常</em> 3.可能是在jedis工具<em>类</em>中出现过时的方法
java.lang.NoClassDefFoundError :问题分析及解决
今天遇到一个恶心的问题:在本地运行正常,但上传服务器<em>报</em>错,错误:java.lang.NoClassDefFoundError 先来看看NoClassDefFoundError和ClassNotFoundException这是两个相似但完全不同两个错误 NoClassDefFoundError和ClassNotFoundException区别 我们经常被java.lang.ClassNotFou...
求助解决这个问题:java.lang.NoClassDefFoundError
求高手解决这个问题,急急!!!在网上查了很多例子都没搞定,不知道是Tomat的问题还是程序本身有误,会的帮个忙吧。。 java.lang.NoClassDefFoundError: org/apach
造成java.lang.NoClassDefFoundError错误的原因及解决办法
1、项目依赖的jar包未全部导入; 如:java.lang.NoClassDefFoundError: Could not initialize class com.esms.common.util.XmlUtil,当你去查这个<em>类</em>的时候发现这个<em>类</em>是存在,之所以抱着个错是 因为在这个<em>类</em>里面的方法引用了其他jar包中的<em>类</em>的方法,而这个被引用的这个jar包刚好缺失,所以抛出这个错。 解决办法:一层
已解决异常:java.lang.NoClassDefFoundError: org/springframework/util/ClassUtils
搭建SSJ项目结构时遇到了一个<em>异常</em>,记录一下(排了好久) java.lang.NoClassDefFoundError: org/<em>spring</em>framework/util/ClassUtils at org.<em>spring</em>framework.test.context.junit4.SpringJUnit4ClassRunner.&amp;lt;clinit&amp;gt;(SpringJUnit4Clas...
org.springframework.data.redis.serializer.SerializationException 解决方案
在使用Spring Data Redis的过程中,<em>报</em>了如下的<em>异常</em> org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Cannot serialize; nested exception is org.<em>spring</em>framework.core.serializer.support.SerializationFaile...
关于redis错SerializationException的两个值得注意的地方
<em>整合</em><em>redis</em>时,遇到序列化<em>异常</em>,<em>报</em>错信息如下: org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Cannot deserialize; nested exception is org.<em>spring</em>framework.core.serializer.support.SerializationFailedExcep...
springredis整合,实例化ConnectionFactory出错
下面是我配置connectionFactory的代码 ``` @Bean public JedisConnectionFactory connectionFactory() throws IOException{ Properties p = new Properties(); // 加载<em>redis</em>配置文件 p.load(CreateBeans.class.getResourceAsStream("/<em>redis</em>.properties")); // 配置JedisPool JedisPoolConfig poolConfig = new JedisPoolConfig(); poolConfig.setMaxIdle(Integer.parseInt(p.getProperty("<em>redis</em>.maxIdle"))); poolConfig.setMaxTotal(Integer.parseInt(p.getProperty("<em>redis</em>.maxTotal"))); poolConfig.setMaxWaitMillis(Integer.parseInt(p.getProperty("<em>redis</em>.maxWaitMillis"))); poolConfig.setTestOnBorrow(Boolean.parseBoolean(p.getProperty("<em>redis</em>.testOnBorrow"))); // 配置连接信息 RedisStandaloneConfiguration standaloneConfig = new RedisStandaloneConfiguration(); standaloneConfig.setHostName(p.getProperty("<em>redis</em>.host")); standaloneConfig.setPort(Integer.parseInt(p.getProperty("<em>redis</em>.port"))); String pass = p.getProperty("<em>redis</em>.pass"); if(pass != null && !pass.equals("")) standaloneConfig.setPassword(RedisPassword.of(pass)); else standaloneConfig.setPassword(RedisPassword.none()); DefaultJedisClientConfigurationBuilder builder = (DefaultJedisClientConfigurationBuilder) JedisClientConfiguration.builder(); builder.usePooling(); builder.poolConfig(poolConfig); builder.connectTimeout(Duration.ofMillis(Integer.parseInt(p.getProperty("<em>redis</em>.connTimeout")))); builder.readTimeout(Duration.ofMillis(Integer.parseInt(p.getProperty("<em>redis</em>.readTimeout")))); JedisClientConfiguration clientConfig = builder.build(); return new JedisConnectionFactory(standaloneConfig, clientConfig); } ``` ![所引用的包](https://img-ask.csdn.net/upload/201806/16/1529135754_444752.png) ![所引用的包](https://img-ask.csdn.net/upload/201806/16/1529135886_501364.png) 以上为引用的包,当然有些是配置<em>redis</em>不需要的。 下面是错误信息, ``` Caused by: java.lang.NoClassDefFoundError: Could not initialize class org.<em>spring</em>framework.data.<em>redis</em>.connection.jedis.JedisConnectionFactory at com.dimbbs.beans.CreateBeans.connectionFactory(CreateBeans.java:43) at com.dimbbs.beans.CreateBeans$$EnhancerBySpringCGLIB$$6ae8678c.CGLIB$connectionFactory$0() at com.dimbbs.beans.CreateBeans$$EnhancerBySpringCGLIB$$6ae8678c$$FastClassBySpringCGLIB$$d2c7309d.invoke() at org.<em>spring</em>framework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228) at org.<em>spring</em>framework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:361) at com.dimbbs.beans.CreateBeans$$EnhancerBySpringCGLIB$$6ae8678c.connectionFactory() at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.<em>spring</em>framework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154) ... 48 more ``` 是不是我缺少什么包?
java redis 不到jar问题
上图![图片说明](https://img-ask.csdn.net/upload/201607/28/1469676896_11832.png)图上所述 jar有pom 有为啥还说<em>找</em><em>不到</em>?
redis 反序列化deserialize异常问题解决
日志如下 org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Cannot deserialize; nested exception is org.<em>spring</em>framework.core.serializer.support.SerializationFailedException: Failed to de...
redis.clients.jedis.exceptions.JedisConnectionException之异常解决
文章简单介绍了<em>redis</em>.clients.jedis.exceptions.JedisConnectionException: java.net.SocketTimeoutException: Read timed out和<em>redis</em>.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool两种<em>异常</em>的产生原因,并最后给出解决方法,亲测有效。
'redis.clients.jedis.JedisPool' that could not be found
*************************** APPLICATION FAILED TO START *************************** Description: Field jedisPool in com.jcn.<em>redis</em>.service.RedisService required a bean of type '<em>redis</em>.clients.jedis.Je
springboot配置中的jedispool bean无法注入jedisUtils工具
在配置<em>类</em>中进行了Jedispool的配置,并返回jedispool,在工具<em>类</em>中获取<em>不到</em>jedispool,返回Null;在测试<em>类</em>中却可以获取到。下面贴代码和断点测试结果:总结就是测试<em>类</em>都可以获取到注入
spring boot整合redis获取异常或者获取不到
系统<em>异常</em>:org.<em>spring</em>framework.data.<em>redis</em>.RedisConnec tionFailureException: Cannot get Jedis connection; nested exception is <em>redis</em>.clients.jedis.exceptions.JedisException: Could not get a resource from the pool 刚启动系统运行正常,过几天就会出现这个<em>异常</em>,以下是关于<em>redis</em>e的配置: # <em>redis</em>.properties文件中的内容如下: <em>redis</em>.hostName=127.0.0.1 <em>redis</em>.password= #端口号 <em>redis</em>.port=6379 #客户端超时时间单位是毫秒 默认是2000 <em>redis</em>.timeout=10000 #最大空闲数 <em>redis</em>.maxIdle=300 #连接池的最大数据库连接数。设为0表示无限制,如果是jedis 2.4以后用<em>redis</em>.maxTotal #<em>redis</em>.maxActive=600 #控制一个pool可分配多少个jedis实例,用来替换上面的<em>redis</em>.maxActive,如果是jedis 2.4以后用该属性 <em>redis</em>.maxTotal=300 #最大建立连接等待时间。如果超过此时间将接到<em>异常</em>。设为-1表示无限制。 <em>redis</em>.maxWaitMillis=1000 #连接的最小空闲时间 默认1800000毫秒(30分钟) <em>redis</em>.minEvictableIdleTimeMillis=300000 #每次释放连接的最大数目,默认3 <em>redis</em>.numTestsPerEvictionRun=1024 #逐出扫描的时间间隔(毫秒) 如果为负数,则不运行逐出线程, 默认-1 <em>redis</em>.timeBetweenEvictionRunsMillis=30000 #是否在从池中取出连接前进行检验,如果检验失败,则从池中去除连接并尝试取出另一个 <em>redis</em>.testOnBorrow=true #在空闲时检查有效性, 默认false <em>redis</em>.testWhileIdle=true # pom.xml中<em>整合</em><em>redis</em>内容如下: org.<em>spring</em>framework.boot <em>spring</em>-boot-starter-data-<em>redis</em> # <em>redis</em>Config内容如下: package com.brons.trans.<em>redis</em>; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.<em>spring</em>framework.beans.factory.annotation.Value; import org.<em>spring</em>framework.context.annotation.Bean; import org.<em>spring</em>framework.context.annotation.Configuration; import org.<em>spring</em>framework.context.annotation.PropertySource; import org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConnectionFactory; import org.<em>spring</em>framework.data.<em>redis</em>.connection.jedis.JedisConnectionFactory; import org.<em>spring</em>framework.data.<em>redis</em>.core.RedisTemplate; import org.<em>spring</em>framework.data.<em>redis</em>.serializer.GenericJackson2JsonRedisSerializer; import org.<em>spring</em>framework.data.<em>redis</em>.serializer.StringRedisSerializer; import <em>redis</em>.clients.jedis.JedisPoolConfig; @Configuration @PropertySource("classpath:<em>redis</em>.properties") public class RedisConfig { Logger logger = LoggerFactory.getLogger(RedisConfig.class); @Value("${<em>redis</em>.hostName}") private String hostName; @Value("${<em>redis</em>.port}") private Integer port; @Value("${<em>redis</em>.password}") private String password; @Value("${<em>redis</em>.timeout}") private Integer timeout; @Value("${<em>redis</em>.maxIdle}") private Integer maxIdle; @Value("${<em>redis</em>.maxTotal}") private Integer maxTotal; @Value("${<em>redis</em>.maxWaitMillis}") private Integer maxWaitMillis; @Value("${<em>redis</em>.minEvictableIdleTimeMillis}") private Integer minEvictableIdleTimeMillis; @Value("${<em>redis</em>.numTestsPerEvictionRun}") private Integer numTestsPerEvictionRun; @Value("${<em>redis</em>.timeBetweenEvictionRunsMillis}") private long timeBetweenEvictionRunsMillis; @Value("${<em>redis</em>.testOnBorrow}") private boolean testOnBorrow; @Value("${<em>redis</em>.testWhileIdle}") private boolean testWhileIdle; // @Value("${<em>spring</em>.<em>redis</em>.cluster.nodes}") // private String clusterNodes; // // @Value("${<em>spring</em>.<em>redis</em>.cluster.max-redirects}") // private Integer mmaxRedirectsac; /** * JedisPoolConfig 连接池 * * @return */ @Bean public JedisPoolConfig jedisPoolConfig() { logger.info("初始化RedisConfig.JedisPoolConfig 连接池===="); JedisPoolConfig jedisPoolConfig = new JedisPoolConfig(); // 最大空闲数 jedisPoolConfig.setMaxIdle(maxIdle); // 连接池的最大数据库连接数 jedisPoolConfig.setMaxTotal(maxTotal); // 最大建立连接等待时间 jedisPoolConfig.setMaxWaitMillis(maxWaitMillis); // 逐出连接的最小空闲时间 默认1800000毫秒(30分钟) jedisPoolConfig.setMinEvictableIdleTimeMillis(minEvictableIdleTimeMillis); // 每次逐出检查时 逐出的最大数目 如果为负数就是 : 1/abs(n), 默认3 jedisPoolConfig.setNumTestsPerEvictionRun(numTestsPerEvictionRun); // 逐出扫描的时间间隔(毫秒) 如果为负数,则不运行逐出线程, 默认-1 jedisPoolConfig.setTimeBetweenEvictionRunsMillis(timeBetweenEvictionRunsMillis); // 是否在从池中取出连接前进行检验,如果检验失败,则从池中去除连接并尝试取出另一个 jedisPoolConfig.setTestOnBorrow(testOnBorrow); // 在空闲时检查有效性, 默认false jedisPoolConfig.setTestWhileIdle(testWhileIdle); return jedisPoolConfig; } /** * 单机版配置 @Title: JedisConnectionFactory @param @param * jedisPoolConfig @param @return @return JedisConnectionFactory @autor * lpl @date 2018年2月24日 @throws */ @Bean public JedisConnectionFactory JedisConnectionFactory(JedisPoolConfig jedisPoolConfig) { logger.info("初始化RedisConfig.JedisConnectionFactory单机版配置===="); JedisConnectionFactory JedisConnectionFactory = new JedisConnectionFactory(jedisPoolConfig); // 连接池 JedisConnectionFactory.setPoolConfig(jedisPoolConfig); // IP地址 JedisConnectionFactory.setHostName(hostName); // 端口号 JedisConnectionFactory.setPort(port); // 如果Redis设置有密码 JedisConnectionFactory.setPassword(password); // 客户端超时时间单位是毫秒 JedisConnectionFactory.setTimeout(timeout); return JedisConnectionFactory; } /** * 实例化 RedisTemplate 对象 * * @return */ @Bean public RedisTemplate functionDomainRedisTemplate(RedisConnectionFactory <em>redis</em>ConnectionFactory) { RedisTemplate <em>redis</em>Template = new RedisTemplate(); initDomainRedisTemplate(<em>redis</em>Template, <em>redis</em>ConnectionFactory); return <em>redis</em>Template; } /** * 设置数据存入 <em>redis</em> 的序列化方式,并开启事务 * * @param <em>redis</em>Template * @param factory */ private void initDomainRedisTemplate(RedisTemplate <em>redis</em>Template, RedisConnectionFactory factory) { // 如果不配置Serializer,那么存储的时候缺省使用String,如果用User<em>类</em>型存储,那么会提示错误User can't cast to // String! <em>redis</em>Template.setKeySerializer(new StringRedisSerializer()); <em>redis</em>Template.setHashKeySerializer(new StringRedisSerializer()); <em>redis</em>Template.setHashValueSerializer(new GenericJackson2JsonRedisSerializer()); <em>redis</em>Template.setValueSerializer(new GenericJackson2JsonRedisSerializer()); // 开启事务 <em>redis</em>Template.setEnableTransactionSupport(true); <em>redis</em>Template.setConnectionFactory(factory); } /** * 注入封装RedisTemplate @Title: <em>redis</em>Util @return RedisUtil @autor lpl @date * 2017年12月21日 @throws */ @Bean(name = "<em>redis</em>Util") public RedisUtil <em>redis</em>Util(RedisTemplate <em>redis</em>Template) { RedisUtil <em>redis</em>Util = new RedisUtil(); <em>redis</em>Util.setRedisTemplate(<em>redis</em>Template); return <em>redis</em>Util; } } # RedisUtil工具<em>类</em>文件内容如下: package com.brons.trans.<em>redis</em>; import java.util.List; import java.util.Map; import java.util.Set; import java.util.concurrent.TimeUnit; import org.<em>spring</em>framework.data.<em>redis</em>.core.RedisTemplate; import org.<em>spring</em>framework.util.CollectionUtils; public class RedisUtil { private RedisTemplate <em>redis</em>Template; public void setRedisTemplate(RedisTemplate <em>redis</em>Template) { this.<em>redis</em>Template = <em>redis</em>Template; } //=============================common============================ /** * 指定缓存失效时间 * @param key 键 * @param time 时间(秒) * @return */ public boolean expire(String key,long time){ try { if(time>0){ <em>redis</em>Template.expire(key, time, TimeUnit.SECONDS); } return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 根据key 获取过期时间 * @param key 键 不能为null * @return 时间(秒) 返回0代表为永久有效 */ public long getExpire(String key){ return <em>redis</em>Template.getExpire(key,TimeUnit.SECONDS); } /** * 判断key是否存在 * @param key 键 * @return true 存在 false不存在 */ public boolean hasKey(String key){ try { return <em>redis</em>Template.hasKey(key); } catch (Exception e) { e.printStackTrace(); return false; } } /** * 删除缓存 * @param key 可以传一个值 或多个 */ @SuppressWarnings("unchecked") public void del(String ... key){ if(key!=null&&key.length>0){ if(key.length==1){ <em>redis</em>Template.delete(key[0]); }else{ <em>redis</em>Template.delete(CollectionUtils.arrayToList(key)); } } } //============================String============================= /** * 普通缓存获取 * @param key 键 * @return 值 */ public Object get(String key){ return key==null?null:<em>redis</em>Template.opsForValue().get(key); } /** * 普通缓存放入 * @param key 键 * @param value 值 * @return true成功 false失败 */ public boolean set(String key,Object value) { try { <em>redis</em>Template.opsForValue().set(key, value); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 普通缓存放入并设置时间 * @param key 键 * @param value 值 * @param time 时间(秒) time要大于0 如果time小于等于0 将设置无限期 * @return true成功 false 失败 */ public boolean set(String key,Object value,long time){ try { if(time>0){ <em>redis</em>Template.opsForValue().set(key, value, time, TimeUnit.SECONDS); }else{ set(key, value); } return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 递增 * @param key 键 * @param by 要增加几(大于0) * @return */ public long incr(String key, long delta){ if(delta hmget(String key){ return <em>redis</em>Template.opsForHash().entries(key); } /** * HashSet * @param key 键 * @param map 对应多个键值 * @return true 成功 false 失败 */ public boolean hmset(String key, Map map){ try { <em>redis</em>Template.opsForHash().putAll(key, map); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * HashSet 并设置时间 * @param key 键 * @param map 对应多个键值 * @param time 时间(秒) * @return true成功 false失败 */ public boolean hmset(String key, Map map, long time){ try { <em>redis</em>Template.opsForHash().putAll(key, map); if(time>0){ expire(key, time); } return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 向一张hash表中放入数据,如果不存在将创建 * @param key 键 * @param item 项 * @param value 值 * @return true 成功 false失败 */ public boolean hset(String key,String item,Object value) { try { <em>redis</em>Template.opsForHash().put(key, item, value); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 向一张hash表中放入数据,如果不存在将创建 * @param key 键 * @param item 项 * @param value 值 * @param time 时间(秒) 注意:如果已存在的hash表有时间,这里将会替换原有的时间 * @return true 成功 false失败 */ public boolean hset(String key,String item,Object value,long time) { try { <em>redis</em>Template.opsForHash().put(key, item, value); if(time>0){ expire(key, time); } return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 删除hash表中的值 * @param key 键 不能为null * @param item 项 可以使多个 不能为null */ public void hdel(String key, Object... item){ <em>redis</em>Template.opsForHash().delete(key,item); } /** * 判断hash表中是否有该项的值 * @param key 键 不能为null * @param item 项 不能为null * @return true 存在 false不存在 */ public boolean hHasKey(String key, String item){ return <em>redis</em>Template.opsForHash().hasKey(key, item); } /** * hash递增 如果不存在,就会创建一个 并把新增后的值返回 * @param key 键 * @param item 项 * @param by 要增加几(大于0) * @return */ public double hincr(String key, String item,double by){ return <em>redis</em>Template.opsForHash().increment(key, item, by); } /** * hash递减 * @param key 键 * @param item 项 * @param by 要减少记(小于0) * @return */ public double hdecr(String key, String item,double by){ return <em>redis</em>Template.opsForHash().increment(key, item,-by); } //============================set============================= /** * 根据key获取Set中的所有值 * @param key 键 * @return */ public Set sGet(String key){ try { return <em>redis</em>Template.opsForSet().members(key); } catch (Exception e) { e.printStackTrace(); return null; } } /** * 根据value从一个set中查询,是否存在 * @param key 键 * @param value 值 * @return true 存在 false不存在 */ public boolean sHasKey(String key,Object value){ try { return <em>redis</em>Template.opsForSet().isMember(key, value); } catch (Exception e) { e.printStackTrace(); return false; } } /** * 将数据放入set缓存 * @param key 键 * @param values 值 可以是多个 * @return 成功个数 */ public long sSet(String key, Object...values) { try { return <em>redis</em>Template.opsForSet().add(key, values); } catch (Exception e) { e.printStackTrace(); return 0; } } /** * 将set数据放入缓存 * @param key 键 * @param time 时间(秒) * @param values 值 可以是多个 * @return 成功个数 */ public long sSetAndTime(String key,long time,Object...values) { try { Long count = <em>redis</em>Template.opsForSet().add(key, values); if(time>0) expire(key, time); return count; } catch (Exception e) { e.printStackTrace(); return 0; } } /** * 获取set缓存的长度 * @param key 键 * @return */ public long sGetSetSize(String key){ try { return <em>redis</em>Template.opsForSet().size(key); } catch (Exception e) { e.printStackTrace(); return 0; } } /** * 移除值为value的 * @param key 键 * @param values 值 可以是多个 * @return 移除的个数 */ public long setRemove(String key, Object ...values) { try { Long count = <em>redis</em>Template.opsForSet().remove(key, values); return count; } catch (Exception e) { e.printStackTrace(); return 0; } } //===============================list================================= /** * 获取list缓存的内容 * @param key 键 * @param start 开始 * @param end 结束 0 到 -1代表所有值 * @return */ public List lGet(String key,long start, long end){ try { return <em>redis</em>Template.opsForList().range(key, start, end); } catch (Exception e) { e.printStackTrace(); return null; } } /** * 获取list缓存的长度 * @param key 键 * @return */ public long lGetListSize(String key){ try { return <em>redis</em>Template.opsForList().size(key); } catch (Exception e) { e.printStackTrace(); return 0; } } /** * 通过索引 获取list中的值 * @param key 键 * @param index 索引 index>=0时, 0 表头,1 第二个元素,依次<em>类</em>推;index 0) expire(key, time); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 将list放入缓存 * @param key 键 * @param value 值 * @param time 时间(秒) * @return */ public boolean lSet(String key, List value) { try { <em>redis</em>Template.opsForList().rightPushAll(key, value); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 将list放入缓存 * @param key 键 * @param value 值 * @param time 时间(秒) * @return */ public boolean lSet(String key, List value, long time) { try { <em>redis</em>Template.opsForList().rightPushAll(key, value); if (time > 0) expire(key, time); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 根据索引修改list中的某条数据 * @param key 键 * @param index 索引 * @param value 值 * @return */ public boolean lUpdateIndex(String key, long index,Object value) { try { <em>redis</em>Template.opsForList().set(key, index, value); return true; } catch (Exception e) { e.printStackTrace(); return false; } } /** * 移除N个值为value * @param key 键 * @param count 移除多少个 * @param value 值 * @return 移除的个数 */ public long lRemove(String key,long count,Object value) { try { Long remove = <em>redis</em>Template.opsForList().remove(key, count, value); return remove; } catch (Exception e) { e.printStackTrace(); return 0; } } }
ClassNotFoundException redis.connection.jedis.JedisClientConfiguration$JedisClientConfigurationBuil
java.lang.IllegalStateException: Failed to introspect Class [org.<em>spring</em>framework.boot.autoconfigure.data.<em>redis</em>.JedisConnectionConfiguration] from ClassLoader [sun.misc.LauncherAppClassLoader@18b4aac2]...
spring boot 项目中redis 序列化异常:org.springframework.data.redis.serializer.SerializationException
<em>spring</em> boot 项目中<em>redis</em> 序列化<em>异常</em> 当配置好<em>redis</em>配置时候,进行测试<em>redis</em>查询缓存,以下是注解配置下的缓存设置代码:java.lang.IllegalArgumentException: DefaultSerializer requires a Serializable payload but received an object of type @Cacheable(v...
maven引入这个插件一直
是maven版本问题吗?
idea解决Could not autowire.No beans of 'xxx' type found
对于这个<em>报</em>错,网上的解决方法大多是隐藏,但不能排除这个确实是程序错误。比如,在controller中 如果出现<em>报</em>错,可能是: 可能是在Service中加@Service 如果确认代码没错,请采用网上流行的隐藏该<em>报</em>错方法。 ...
spring data redis serializer SerializationException 序列化问题
speing data <em>redis</em> serializer SerializationException 序列化问题 项目中需要使用<em>redis</em>做一些缓存失效,以达到验证码失效的目的。由于K,V使用了,,验证验证码是否存在,是否达到规定次数。参看了官方文档(内容很少),碰到了序列化的问题,<em>异常</em>如下: org.<em>spring</em>framework.data.<em>redis</em>.serializer.Ser
Caused by java.lang.NoClassDefFoundError redisclientsutilPool
&lt;!--jedis--&gt; &lt;dependency&gt; &lt;groupId&gt;<em>redis</em>.clients&lt;/groupId&gt; &lt;artifactId&gt;jedis&lt;/artifactId&gt; &lt;version&gt;2.9.0&lt;/version&gt; &lt;/dependency&gt; &lt;!...
idea的Could not autowire. No beans of 'xxxx' type found
1、引入实体<em>报</em>错: Could not autowire. No beans of ‘xxxx’ type found 2、解决方式: File–&gt;Settings–&gt;Editor–&gt;Inspections–&gt;搜索框输入【<em>spring</em>】—&gt;Spring Code----&gt;Code—&gt;Autowiring for Bean Class ----&gt;Sev...
java.lang.NoClassDefFoundError
![图片说明](https://img-ask.csdn.net/upload/201705/03/1493780867_650176.png) linux下使用jedis,运行目录如上图,Main.java内容: ``` import <em>redis</em>.clients.jedis.exceptions.*; import <em>redis</em>.clients.jedis.*; import <em>redis</em>.clients.util.*; import org.apache.commons.pool2.*; import org.apache.commons.pool2.proxy.*; import org.apache.commons.pool2.impl.*; public class Main{ public static void main(String[] args){ Jedis jedis = new Jedis("127.0.0.1",6379); jedis.set("s2","123"); String result = jedis.get("s2"); System.out.println(result); jedis.close(); } } ``` 进入该目录下执行 javac -cp jedis-2.7.0.jar:commons-pool2-2.3.jar: Main.java 编译成功,然后运行 java Main<em>报</em>错: Exception in thread "main" java.lang.NoClassDefFoundError: <em>redis</em>/clients/jedis/Jedis at Main.main(Main.java:20) Caused by: java.lang.ClassNotFoundException: <em>redis</em>.clients.jedis.Jedis at java.net.URLClassLoader$1.run(URLClassLoader.java:366) at java.net.URLClassLoader$1.run(URLClassLoader.java:355) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:354) at java.lang.ClassLoader.loadClass(ClassLoader.java:425) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) ... 1 more 编译成功了,但是运行时却<em>找</em><em>不到</em><em>类</em>?还是说编译其实也有问题,在Main.java中已经把两个外部jar包的所有<em>类</em>都import了。查了网上不少资料了但是还是没解决,平常都用IDE的,这次试试用javac然后就这样了。求解答,谢谢。
Jedis操作redis工具 JedisUtil
package com.wxj.common; import java.util.List; import java.util.Map; import java.util.Set; import <em>redis</em>.clients.jedis.BinaryClient.LIST_POSITION; import <em>redis</em>.clients.jedis.Jedis; import <em>redis</em>.clien
org.springframework.data.redis.serializer.SerializationException: Could not read JSON: 1801; nested
问题描述: 使用<em>redis</em>存储一条String<em>类</em>型的数据,在get数据时<em>报</em>错:org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Could not read JSON: 1801; nested exception is java.lang.ArrayIndexOutOfBoundsException。 问题猜想...
java.lang.ClassNotFoundException: redis.clients.jedis.util.SafeEncoder
jedis版本2.9.0,<em>报</em>错: Caused by: org.<em>spring</em>framework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name '<em>redis</em>HealthContributor' defined in class path resource [org/<em>spring</em>framework...
org.springframework.data.redis.serializer.SerializationException
错误描述:Cannot deserialize; nested exception is org.<em>spring</em>framework.core.serializer.support.SerializationFailedException: Failed to deserialize payload. Is the byte array a result of corresponding serial...
Redis使用Pipeline时对象序列化失败org.springframework.data.redis.serializer.SerializationException
为了能提升项目中<em>redis</em>对数据库操作的速度,打算在代码中引入pipeline机制。 原先项目中对于RedisTemplate的定义是 private RedisTemplate&lt;String, Object&gt; <em>redis</em>Template; 在configuration中设置的序列化是 @Bean public RedisTemplate&lt;String...
Spring mvc 整合redis 实例化bean出现问题
org.<em>spring</em>framework.beans.factory.BeanCreationException: Error creating bean with name 'jedisConnectionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Instantiation of bean failed; nested exception is java.lang.VerifyError: Bad type on operand stack Exception Details: Location: org/<em>spring</em>framework/data/<em>redis</em>/connection/jedis/JedisConnectionFactory.createRedisPool()L<em>redis</em>/clients/util/Pool; @37: invokespecial Reason: Type '<em>redis</em>/clients/jedis/JedisPoolConfig' (current frame, stack[2]) is not assignable to 'org/apache/commons/pool2/impl/GenericObjectPoolConfig' Current Frame: bci: @37 flags: { } locals: { 'org/<em>spring</em>framework/data/<em>redis</em>/connection/jedis/JedisConnectionFactory' } stack: { uninitialized 0, uninitialized 0, '<em>redis</em>/clients/jedis/JedisPoolConfig', 'java/lang/String', integer, integer, 'java/lang/String' } Bytecode: 0x0000000: bb00 2c59 2ab6 0028 2ab6 0012 b600 2d2a 0x0000010: b600 12b6 002e 2a2a b600 12b7 0029 2ab6 0x0000020: 0012 b600 2ab7 002f b0 at org.<em>spring</em>framework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1007) at org.<em>spring</em>framework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:953) at org.<em>spring</em>framework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:487) at org.<em>spring</em>framework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:458) at org.<em>spring</em>framework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:295) at org.<em>spring</em>framework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:223) at org.<em>spring</em>framework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:292) at org.<em>spring</em>framework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194) at org.<em>spring</em>framework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:628) at org.<em>spring</em>framework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:932) at org.<em>spring</em>framework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:479) at org.<em>spring</em>framework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:389) at org.<em>spring</em>framework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:294) at org.<em>spring</em>framework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112) at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4760) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5184) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:714) at org.apache.catalina.startup.HostConfig.manageApp(HostConfig.java:1588) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:463) at org.apache.catalina.mbeans.MBeanFactory.createStandardContext(MBeanFactory.java:413) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801) at javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1468) at javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:76) at javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1309) at javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1401) at javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:829) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:324) at sun.rmi.transport.Transport$1.run(Transport.java:200) at sun.rmi.transport.Transport$1.run(Transport.java:197) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:196) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:683) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:682) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.VerifyError: Bad type on operand stack Exception Details: Location: org/<em>spring</em>framework/data/<em>redis</em>/connection/jedis/JedisConnectionFactory.createRedisPool()L<em>redis</em>/clients/util/Pool; @37: invokespecial Reason: Type '<em>redis</em>/clients/jedis/JedisPoolConfig' (current frame, stack[2]) is not assignable to 'org/apache/commons/pool2/impl/GenericObjectPoolConfig' Current Frame: bci: @37 flags: { } locals: { 'org/<em>spring</em>framework/data/<em>redis</em>/connection/jedis/JedisConnectionFactory' } stack: { uninitialized 0, uninitialized 0, '<em>redis</em>/clients/jedis/JedisPoolConfig', 'java/lang/String', integer, integer, 'java/lang/String' } Bytecode: 0x0000000: bb00 2c59 2ab6 0028 2ab6 0012 b600 2d2a 0x0000010: b600 12b6 002e 2a2a b600 12b7 0029 2ab6 0x0000020: 0012 b600 2ab7 002f b0 at java.lang.Class.getDeclaredConstructors0(Native Method) at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671) at java.lang.Class.getConstructor0(Class.java:3075) at java.lang.Class.getDeclaredConstructor(Class.java:2178) at org.<em>spring</em>framework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:78) at org.<em>spring</em>framework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1000) ... 58 more
反序列化失败
var test = $("#sendForm").serialize(); 网上搜的方法 public List JSONStringToList<APP_RIDECOS
spring-boot-starter-data-redis不到RedisTemplate
pom.xml org.<em>spring</em>framework.boot <em>spring</em>-b
Caused by: java.lang.ClassNotFoundException常见异常解决方法!
常见的Caused by: java.lang.ClassNotFoundException<em>异常</em>原因:ClassNotFoundException属于checkException(检查<em>异常</em>),一般在项目启动的时候出现。出现该问题原因归纳为:1. 没有正确的导入jar导致。2. 项目中引用了多个版本的jar,导致版本冲突,由于版本的升级,可能所使用的方法已经被废弃。3. 由于系统中加载web.xml...
redis反序列化异常:org.springframework.data.redis.serializer.SerializationException
1、日志如下 org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationException: Cannot deserialize; nested exception is org.<em>spring</em>framework.core.serializer.support.SerializationFailedException: Failed to d...
GenericJackson2JsonRedisSerializer 反序列化问题
在使用Spring-data-<em>redis</em> 时, 很多文章都推荐使用GenericJackson2JsonRedisSerializer 作为<em>redis</em>Template 的序列化执行器, 然而,在遇到<em>类</em>中有 LocalDateTime 等<em>类</em>型时, 反序列化会有问题,大概错误提示为: org.<em>spring</em>framework.data.<em>redis</em>.serializer.SerializationEx...
jmeter之Java request错:java.lang.NoClassDefFoundError: redis/clients/jedis/Jedis
今天在学习Jmeter的java request,请求内容是连接<em>redis</em>并获取其中的一个字段值。结果在运行时<em>报</em>如下错误: 2018/05/24 13:08:20 ERROR - jmeter.threads.JMeterThread: Test failed! java.lang.NoClassDefFoundError: <em>redis</em>/clients/jedis/Jedis ...
Type 'redis/clients/jedis/JedisPoolConfig' (current frame, stack[1]) is not assignable to 'org/apach
Type '<em>redis</em>/clients/jedis/JedisPoolConfig' (current frame, stack[1]) is not assignable to 'org/apache/commons/pool2/impl/GenericObjectPoolConfig'   jar 包版本不匹配 前 : <em>redis</em>.clients.jedis 2.10 升级到 2.9.0可...
nested exception is java.lang.NoClassDefFoundError
org.<em>spring</em>framework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML doc
jedisConnectionFactory不到
<em>spring</em>-data-<em>redis</em> 与jedis 版本匹配问题 <em>spring</em>-data-<em>redis</em>2.1.9搭配jedis 3.0.1会<em>报</em>错,替换一个较低版本的jedis 具体<em>报</em>错 Caused by: org.<em>spring</em>framework.beans.factory.BeanCreationException: Error creating bean with na...
'org.springframework.data.redis.connection.RedisConnectionFactory' that could not be found
Description: Field connectionFactory in com.lee.securityoauth2.config.AuthorizationServerConfig required a bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConnectionFactory' that could ...
Jedis Util
package com.iclass.esb.engine.cache.<em>redis</em>; import com.iclass.esb.engine.cache.ESBCache; import org.apache.commons.lang3.StringUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; i
Springboot RedisTemplate No qualifying bean of type... 不能按型装配注入
最近在做一个项目,项目地址: https://github.com/wangyuanjun008/wyj-<em>spring</em>boot-security.git 在项目中与<em>redis</em>集成,使用的依赖是: org.<em>spring</em>framework.boot <em>spring</em>-boot-starter-data-<em>redis</em> 在Controller中使
jar包冲突那些事,编译器不错,启动
上周启动项目遇到了错误一,这周启动遇到错误二。       在分布式系统中,那么多复杂繁琐的jar依赖,遇到jar包冲突是常有的事。       假如,你也经常遇到这样的情况——明明编译的时候是好好的,可就是启动的时候不成功,明明jar包是有的,可就是<em>报</em><em>找</em><em>不到</em><em>类</em>,或<em>找</em><em>不到</em>方法?       为了解决这样的困扰,遂写下此文,顺便聊一聊。 错误一:java.lang.NoCla
SpringBoot中注入RedisTemplate实例异常解决
最近,在项目开发过程中使用了RedisTemplate,进行单元测试时提示“Field <em>redis</em>Template in com.example.demo1.dao.RedisDao required a bean of type ‘org.<em>spring</em>framework.data.<em>redis</em>.core.RedisTemplate’ that could not be found”,翻译过来就是“...
Spring整合Redis之ConnectionFactory从何而来?
最近在学习Redis的时候,入门的时候看了个demo @Bean public RedisTemplate&lt;String, Object&gt; <em>redis</em>Template(RedisConnectionFactory connectionFactory){ RedisTemplate&lt;String, Object&gt; template = new Redi...
java.lang.NoClassDefFoundError: redis/clients/j...
为什么80%的码农都做不了架构师?&gt;&gt;&gt; ...
java lang NoClassDefFoundError redis/clients/jedis/exceptio
java lang NoClassDefFoundError <em>redis</em>/clients/jedis/exceptio
Could not autowire. No beans of 'XXXRepository' type found.less...
@RestController public class GirlController { @Autowired private GirlRepository girlRepository; @Get
springboot整合redis
Error starting ApplicationContext. To display the auto-configuration report re-run your application with 'debug' enabled. 2018-10-29 11:27:12.945 ERROR 6612 --- [ restartedMain] o.s.b.d.LoggingFailureAnalysisReporter : *************************** APPLICATION FAILED TO START *************************** Description: Parameter 0 of method <em>redis</em>Template in com.wisezone.<em>spring</em>boot.<em>redis</em>.RedisConfig required a bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConnectionFactory' that could not be found. - Bean method '<em>redis</em>ConnectionFactory' not loaded because @ConditionalOnClass did not find required class 'org.apache.commons.pool2.impl.GenericObjectPool' Action: Consider revisiting the conditions above or defining a bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.connection.RedisConnectionFactory' in your configuration. Process finished with exit code 0 求救啊,<em>整合</em>了一整天都是<em>报</em>这个错,甚至连git别人的项目也还是<em>报</em>这个错,咋整啊各位大佬
针对Redis实例JedisPool提示JedisPoolConfig错问题
The constructor JedisPool(GenericObjectPoolConfig, String) refers to the missing type GenericObjectPoolConfig
redis客户端之jedis 操作工具
<em>redis</em>客户端之jedis 操作工具<em>类</em> 包括连接池的使用及 jedis对string 、set、sortset、list、hash的所有常规操作。 <em>redis</em>.properties文件: #\u63A7\u5236\u4E00\u4E2Apool\u53EF\u5206\u914D\u591A\u5C11\u4E2Ajedis\u5B9E\u4F8B\uFF0C\u901A\u8FC7...
IntelliJ Idea解决Could not autowire. No beans of 'xxxx' type found的错误提示
1.问题描述   在Idea的<em>spring</em>工程里,经常会遇到Could not autowire. No beans of 'xxxx' type found的错误提示。但程序的编译和运行都是没有问题的,这个错误提示并不会产生影响。但红色的错误提示在有些有强迫症的程序员眼里,多多少少有些不太舒服。   2. 原因   <em>spring</em> auto scan配置,在编辑情况下,无法<em>找</em><em>不到</em>对应的
Could not autowire. No beans of 'xxxx' type found的错误提示
新导出的项目,总出现Could not autowire. No beans of 'xxxx' type found的错误提示, 现在有两个解决办法 1:降低Autowired检测的级别,将Severity的级别由之前的error改成warning或其它可以忽略的级别。 如果没有效果,看方法二 2:在接口的class 加入@Component,如第一个截图的 UserInfoMa...
Spring Boot 2.x注入RedisTemplate失败。启动
文章目录<em>报</em>错内容错误原因解决办法手动写RedisConfig配置<em>类</em>使用lettuce(未实战) <em>报</em>错内容 使用@Autowired注入RedisTemplate的时候,项目启动<em>报</em>错 Field <em>redis</em>Template in com.**.***.*** required a bean of type 'org.<em>spring</em>framework.data.<em>redis</em>.core.RedisTempl...
SpringBoot引入Redisorg.springframework.data.redis.core.RedisTemplate不到错误
今日在学习Redis时,发现导入RedisTemplate和RedisCacheManager失败,反复思索,终于<em>找</em>到解决办法,至此记下以便日后查阅。 pom.xml引入如下: &amp;amp;amp;lt;dependency&amp;amp;amp;gt; &amp;amp;amp;lt;groupId&amp;amp;amp;gt;org.<em>spring</em>framework.data&amp;amp;amp;lt;/groupId&amp;amp;amp;gt; &amp;amp;a
Caused by: java.lang.NoClassDefFoundError: HttpSessionEvent
网上查了下,缺少jar包,然后解决方法是把servlet-api.jar这个包加入到项目工程中,或者把tomcat的library加入到项目中即可 然后我的这里的话,就是把tomcat的library引入即可 ...
RedisTemplate that could not be found如何解决?
解决方法: 把泛型去掉 @Autowired private RedisTemplate&amp;lt;String, Long&amp;gt; template;
springboot整合redis简单操作!!!!
1、什么是<em>redis</em> Redis的的是完全开源免费的,遵守BSD协议,是一个高性能的键值数据库。是当前最热门的的的NoSql数据库之一,也被人们称为数据结构服务器。Redis 把整个数据库全加载到内存当中进行操作,通过异步操作定期把数据库数据 flush 到硬盘上保存。因为是纯内存操作,所以 Redis 的性能非常出色,每秒处理 10 万次以上的读写操作,是已知性能最快的 Key-Value 数据...
Redis-RedisUtils工具
概述:        本文不对<em>redis</em>再做相关详细的介绍,有关<em>redis</em>的相关基础知识及安装,数据结构,命令等请参考菜鸟教程中<em>redis</em>的相关介绍,通俗易懂。本篇文章仅仅针对实际中的开发对<em>redis</em>的操作进行封装。该工具<em>类</em>在jedis对<em>redis</em>操作封装的基础上近一步进行封装,在实际的开发中直接调用即可。由于方法太多,过于详细,在实际项目中可截取部分方法进行使用。由于该工具<em>类</em>中在加载<em>redis</em>...
Spring+Redis的整合问题,No qualifying bean of type ...
在项目中使用Maven+<em>spring</em>+<em>redis</em>,但是在运行服务器的时候<em>报</em>错:以下是我的配置文件 applicationContext-<em>redis</em>.xml: ``` ``` <em>redis</em>ServiceImpl.java: ``` package org.zh.service.impl; import org.<em>spring</em>framework.beans.factory.annotation.Autowired; import org.<em>spring</em>framework.stereotype.Component; import org.<em>spring</em>framework.transaction.annotation.Transactional; import org.zh.service.IRedisService; import <em>redis</em>.clients.jedis.ShardedJedis; import <em>redis</em>.clients.jedis.ShardedJedisPool; import javax.annotation.Resource; /** * Created by ZhaoHang on 2016/7/19. */ @Component @Transactional(readOnly = true) public class RedisServiceImpl implements IRedisService { @Autowired private ShardedJedisPool shardedJedisPool; @Override public void setValue(String key, String val) { ShardedJedis jedis = null; try{ jedis = shardedJedisPool.getResource(); jedis.set(key, val); } catch (Exception e){ e.printStackTrace(); } finally{ if(jedis != null) jedis.close(); } } @Override public String getValue(String key) { ShardedJedis jedis = null; jedis = shardedJedisPool.getResource(); return jedis.get(key); } }
redis无法获得连接池异常
描述: 系统与storm结合使用,数据量较大,<em>redis</em>读写频繁,maxclients最大时有1150多; 出现以下<em>异常</em>时,我的系统已做过如下处理,可是问题依然,求大神指点: 1、我的<em>redis</em>客户端
RedisUtil工具,Java单例模式实现
基于Java单例模式和Jedis封装的RedisUtil,提供了Redis中的Key、字符串、Hash、ZSet等的操作。package com.cumt.tools.<em>redis</em>;import com.alibaba.fastjson.JSON; import com.cumt.framework.config.ConfigHelper; import com.google.common.colle
运行项目Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger
错误内容: ?? 07, 2016 12:01:08 ?? org.apache.catalina.core.ContainerBase addChildInternal ??: ContainerB
jedis与springmvc 集成,JedisPoolConfig 不到异常
最近需要用<em>redis</em>和<em>spring</em>mvc做集成,于是我根据网上的例子在现有框架上集成jedis 1.使用jedis-2.7.3.jar(已检查过没有重复包,”cvtrl+左键“可以<em>找</em>到该<em>类</em>) 2.现在框架中已经集成了memcached,shiro,mybaits(不知道是否有冲突) 3.建立了<em>spring</em>-context-<em>redis</em>.xml文件,文件内容如下: ``` ``` 运行后<em>报</em>错: ``` Caused by: java.lang.ClassNotFoundException: <em>redis</em>.clients.jedis.JedisPoolConfig ``` 对这问题百度各种搜,搜到国外一个哥们也出现了这种情况,但是没有人解答 有遇到过同样问题的兄弟或者能帮我指点一下的高手吗? 如果我有描述不周的地方请各位指出,我会再增加详尽描述 感激不尽
求大神告诉我怎么解决java.lang.NoClassDefFoundError: com/sun/mail/util/QEncoderStream
<em>报</em>错如图 求大神告知怎么去解决 谢谢 MyEclipse用的是8.5的版本
大学四年自学走来,这些私藏的实用工具/学习网站我贡献出来了
大学四年,看课本是不可能一直看课本的了,对于学习,特别是自学,善于搜索网上的一些资源来辅助,还是非常有必要的,下面我就把这几年私藏的各种资源,网站贡献出来给你们。主要有:电子书搜索、实用工具、在线视频学习网站、非视频学习网站、软件下载、面试/求职必备网站。 注意:文中提到的所有资源,文末我都给你整理好了,你们只管拿去,如果觉得不错,转发、分享就是最大的支持了。 一、电子书搜索 对于大部分程序员...
原创软件:快挑,快速挑图下载
出去游玩回来有很多图片吧,要分发给每个人,要一个一个地挑?太麻烦,使用快挑,一边浏览一边就挑图了。看一遍就挑完,非常快捷。 相关下载链接:[url=//download.csdn.net/download/dangerhu/4802842?utm_source=bbsseo]//download.csdn.net/download/dangerhu/4802842?utm_source=bbsseo[/url]
一个android的小游戏下载
android的小游戏,适合于刚刚学android的人学习 相关下载链接:[url=//download.csdn.net/download/littlezan/5526117?utm_source=bbsseo]//download.csdn.net/download/littlezan/5526117?utm_source=bbsseo[/url]
电气控制与PLC应用 项目一.ppt下载
电气控制与PLC自动化控制及相关工厂自动化设备应用实例 相关下载链接:[url=//download.csdn.net/download/lfjd1207/8853159?utm_source=bbsseo]//download.csdn.net/download/lfjd1207/8853159?utm_source=bbsseo[/url]
我们是很有底线的