服务报nacos链接异常,无法链接等。

Blade 未结 0 1104
153934475
153934475 剑圣 2021-10-26 11:05

一、该问题的重现步骤是什么?

1. 系统运行一段时间,可能1-3天不等,出现nacos链接不上。

2. 

3.


二、你期待的结果是什么?实际看到的又是什么?

希望保持nacos链接的稳定性

三、你正在使用的是什么产品,什么版本?在什么操作系统上?

spring cloud 2.8.2,在centos7.8上,nacos2.0.1,如图项目的集群情况。

image.png

四、请提供详细的错误堆栈信息,这很重要。

2021-10-25 22:14:52.228 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={}, requestId='null'}, retryTimes=0,errorMessage=java.util.concurrent.TimeoutException: Waited 3000 milliseconds (plus 6314 milliseconds, 839650 nanoseconds delay) for com.alibaba.nacos.shaded.io.grpc.stub.ClientCalls$GrpcFuture@71519140[status=PENDING, info=[GrpcFuture{clientCall={delegate={delegate=ClientCallImpl{method=MethodDescriptor{fullMethodName=Request/request, type=UNARY, idempotent=false, safe=false, sampledToLocalTracing=true, requestMarshaller=com.alibaba.nacos.shaded.io.grpc.protobuf.lite.ProtoLiteUtils$MessageMarshaller@a746c7f5, responseMarshaller=com.alibaba.nacos.shaded.io.grpc.protobuf.lite.ProtoLiteUtils$MessageMarshaller@45fece32, schemaDescriptor=com.alibaba.nacos.api.grpc.auto.RequestGrpc$RequestMethodDescriptorSupplier@d4ee5bbe}}}}}]]

2021-10-25 22:15:01.017 ERROR 1 --- [  XNIO-1 task-1] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceListRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 22:15:01.012 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 22:15:03.213 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 22:15:06.216 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=1,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 22:15:03.212 ERROR 1 --- [  XNIO-1 task-1] c.a.c.n.discovery.NacosDiscoveryClient   : get service name from nacos server fail,

com.alibaba.nacos.api.exception.NacosException: Request nacos server failed: 

        at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.requestToServer(NamingGrpcClientProxy.java:227)

        at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.getServiceList(NamingGrpcClientProxy.java:175)

        at com.alibaba.nacos.client.naming.remote.NamingClientProxyDelegate.getServiceList(NamingClientProxyDelegate.java:137)

        at com.alibaba.nacos.client.naming.NacosNamingService.getServicesOfServer(NacosNamingService.java:440)

        at com.alibaba.nacos.client.naming.NacosNamingService.getServicesOfServer(NacosNamingService.java:428)

        at com.alibaba.cloud.nacos.discovery.NacosServiceDiscovery.getServices(NacosServiceDiscovery.java:69)

        at com.alibaba.cloud.nacos.discovery.NacosDiscoveryClient.getServices(NacosDiscoveryClient.java:67)

        at org.springframework.cloud.client.discovery.composite.CompositeDiscoveryClient.getServices(CompositeDiscoveryClient.java:67)

        at org.springframework.cloud.client.discovery.health.DiscoveryClientHealthIndicator.health(DiscoveryClientHealthIndicator.java:74)

        at org.springframework.cloud.client.discovery.health.DiscoveryCompositeHealthContributor.lambda$asHealthIndicator$0(DiscoveryCompositeHealthContributor.java:77)

        at org.springframework.cloud.client.discovery.health.DiscoveryCompositeHealthContributor$$Lambda$1375/0000000078187D40.health(Unknown Source)

        at org.springframework.boot.actuate.health.HealthIndicator.getHealth(HealthIndicator.java:37)

        at org.springframework.boot.actuate.health.HealthEndpointWebExtension.getHealth(HealthEndpointWebExtension.java:85)

        at org.springframework.boot.actuate.health.HealthEndpointWebExtension.getHealth(HealthEndpointWebExtension.java:44)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getContribution(HealthEndpointSupport.java:99)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getAggregateHealth(HealthEndpointSupport.java:110)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getContribution(HealthEndpointSupport.java:96)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getAggregateHealth(HealthEndpointSupport.java:110)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getContribution(HealthEndpointSupport.java:96)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getHealth(HealthEndpointSupport.java:74)

        at org.springframework.boot.actuate.health.HealthEndpointSupport.getHealth(HealthEndpointSupport.java:61)

        at org.springframework.boot.actuate.health.HealthEndpointWebExtension.health(HealthEndpointWebExtension.java:71)

        at org.springframework.boot.actuate.health.HealthEndpointWebExtension.health(HealthEndpointWebExtension.java:60)

        at sun.reflect.GeneratedMethodAccessor369.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

        at java.lang.reflect.Method.invoke(Unknown Source)

        at org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:282)

        at org.springframework.boot.actuate.endpoint.invoke.reflect.ReflectiveOperationInvoker.invoke(ReflectiveOperationInvoker.java:77)

        at org.springframework.boot.actuate.endpoint.annotation.AbstractDiscoveredOperation.invoke(AbstractDiscoveredOperation.java:60)

        at org.springframework.boot.actuate.endpoint.web.servlet.AbstractWebMvcEndpointHandlerMapping$ServletWebOperationAdapter.handle(AbstractWebMvcEndpointHandlerMapping.java:305)

        at org.springframework.boot.actuate.endpoint.web.servlet.AbstractWebMvcEndpointHandlerMapping$OperationHandler.handle(AbstractWebMvcEndpointHandlerMapping.java:388)

        at sun.reflect.GeneratedMethodAccessor367.invoke(Unknown Source)

        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

        at java.lang.reflect.Method.invoke(Unknown Source)

        at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:190)

        at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138)

        at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:105)

        at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:878)

        at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:792)

        at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)

        at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040)

        at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943)

        at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006)

        at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:497)

        at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:584)

        at io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:74)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:129)

        at org.springblade.core.log.filter.LogTraceFilter.doFilter(LogTraceFilter.java:39)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at org.springblade.core.boot.request.BladeRequestFilter.doFilter(BladeRequestFilter.java:58)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100)

        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93)

        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.doFilterInternal(WebMvcMetricsFilter.java:97)

        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201)

        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)

        at io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:61)

        at io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:131)

        at io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:84)

        at io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:62)

        at io.undertow.servlet.handlers.ServletChain$1.handleRequest(ServletChain.java:68)

        at io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)

        at io.undertow.servlet.handlers.RedirectDirHandler.handleRequest(RedirectDirHandler.java:68)

        at io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:111)

        at io.undertow.servlet.handlers.security.ServletAuthenticationCallHandler.handleRequest(ServletAuthenticationCallHandler.java:57)

        at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)

        at io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:46)

        at io.undertow.servlet.handlers.security.ServletConfidentialityConstraintHandler.handleRequest(ServletConfidentialityConstraintHandler.java:64)

        at io.undertow.security.handlers.AuthenticationMechanismsHandler.handleRequest(AuthenticationMechanismsHandler.java:60)

        at io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:77)

        at io.undertow.security.handlers.AbstractSecurityContextAssociationHandler.handleRequest(AbstractSecurityContextAssociationHandler.java:43)

        at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)

        at io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:43)

        at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:269)

        at io.undertow.servlet.handlers.ServletInitialHandler.access$100(ServletInitialHandler.java:78)

        at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:133)

        at io.undertow.servlet.handlers.ServletInitialHandler$2.call(ServletInitialHandler.java:130)

        at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:48)

        at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)

        at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:249)

        at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:78)

        at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:99)

        at io.undertow.server.Connectors.executeRootHandler(Connectors.java:390)

        at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:836)

        at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)

        at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:2019)

        at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1558)

        at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1449)

        at java.lang.Thread.run(Unknown Source)

Caused by: com.alibaba.nacos.api.exception.NacosException: Client not connected,current status:UNHEALTHY

        at com.alibaba.nacos.common.remote.client.RpcClient.request(RpcClient.java:656)

        at com.alibaba.nacos.common.remote.client.RpcClient.request(RpcClient.java:636)

        at com.alibaba.nacos.client.naming.remote.gprc.NamingGrpcClientProxy.requestToServer(NamingGrpcClientProxy.java:217)

        ... 101 common frames omitted

2021-10-25 22:15:24.092 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 22:15:33.533 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 23:40:09.458 ERROR 1 --- [aming.updater.0] com.alibaba.nacos.common.remote.client   : Send request fail, request=ServiceQueryRequest{headers={app=unknown}, requestId='null'}, retryTimes=0,errorMessage=Client not connected,current status:UNHEALTHY

2021-10-25 23:45:07.472  WARN 1 --- [  XNIO-1 task-3] c.a.druid.pool.DruidAbstractDataSource   : discard long time none received connection. , jdbcUrl : jdbc:mysql://192.168.1.21:31360/xj9gg_validation?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&transformedBitIsBoolean=true&tinyInt1isBit=false&allowMultiQueries=true&serverTimezone=Asia/Shanghai, version : 1.2.5, lastPacketReceivedIdleMillis : 5399927

2021-10-26 06:02:38.431  WARN 1 --- [  XNIO-1 task-3] com.alibaba.druid.pool.DruidDataSource   : get connection timeout retry : 1

2021-10-26 06:51:14.031  INFO 1 --- [  XNIO-1 task-3] o.s.core.log.aspect.RequestLogAspect     : 

===============  Response Start  ================

<=== GET: /client/validation/merge/get-by-id (31002162 ms)

===============   Response End   ================


五、若有更多详细信息,请在下面提供。

回答
  • 消灭零回复
提交回复