Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No extra connection: All servers are broken. #259

Open
liuyang0508 opened this issue Nov 16, 2023 · 2 comments
Open

No extra connection: All servers are broken. #259

liuyang0508 opened this issue Nov 16, 2023 · 2 comments

Comments

@liuyang0508
Copy link

nebulagraph: 3.5.0
ngbatis: 1.1.5

server:
  port: 8538
  servlet:
    context-path: /geoTracker
#  session:
#    timeout: 1800

nebula:
  ngbatis:
    session-life-length: 300000
    check-fixed-rate: 300000
    # space name needs to be informed through annotations(@Space) or xml(space="test")
    # default false(false: Session pool map will not be initialized)
    use-session-pool: false
  hosts: xxx
  username: xxx
  password: xxx
  space: optical_cable_backbone_network
  pool-config:
    min-conns-size: 0
    max-conns-size: 10
    timeout: 6000
    idle-time: 3000
    interval-idle: -1
    wait-time: 6000
    min-cluster-health-rate: 1.0
    enable-ssl: false

logging:
  level:
    org.nebula.contrib: DEBUG

No extra connection: All servers are broken.
``
2023-11-16 16:35:29.100 DEBUG 39948 --- [nio-8538-exec-4] o.n.contrib.ngbatis.proxy.MapperProxy :
- proxyMethod: null#null
- session space: nullnull
- nGql:
MATCH (d1:Device)-[:hasChild]-(t1:Terminal)-[:connectedTo]-(m:OpticalCircuit)-[:connectedTo]-(t2:Terminal)-[:hasChild]-(d2:Device) where id(m) == '627ec6dde9469c003e7b62fe8ebfbbc5' and m.OpticalCircuit.tenantId == '0' RETURN t1.Terminal.name as devicePortA,t2.Terminal.name as devicePortZ,d1.Device.name as deviceNameA,d2.Device.name as deviceNameZ

- params: {p0=宁波鄞县-宁波市慈溪市CX龙山汇聚FC001WDM(北环主用)}
- result:null

2023-11-16 16:35:29.104 ERROR 39948 --- [nio-8538-exec-4] o.a.c.c.C.[.[.[.[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [/geoTracker] threw exception [Request processing failed; nested exception is org.nebula.contrib.ngbatis.exception.QueryException: 数据查询失败:com.vesoft.nebula.client.graph.exception.NotValidConnectionException: No extra connection: All servers are broken.] with root cause

com.vesoft.nebula.client.graph.exception.NotValidConnectionException: No extra connection: All servers are broken.
at com.vesoft.nebula.client.graph.net.NebulaPool.getConnection(NebulaPool.java:237) ~[client-3.5.0.jar:na]
at com.vesoft.nebula.client.graph.net.NebulaPool.getSession(NebulaPool.java:159) ~[client-3.5.0.jar:na]
at org.nebula.contrib.ngbatis.Env.openSession(Env.java:112) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.session.IntervalCheckSessionDispatcher.newLocalSession(IntervalCheckSessionDispatcher.java:113) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.session.IntervalCheckSessionDispatcher.poll(IntervalCheckSessionDispatcher.java:98) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.proxy.MapperProxy.executeWithParameter(MapperProxy.java:220) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.proxy.MapperProxy.invoke(MapperProxy.java:131) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.proxy.MapperProxy.invoke(MapperProxy.java:169) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.proxy.MapperProxy.pageSupport(MapperProxy.java:185) ~[ngbatis-1.1.5.jar:1.1.5]
at org.nebula.contrib.ngbatis.proxy.MapperProxy.invoke(MapperProxy.java:89) ~[ngbatis-1.1.5.jar:1.1.5]
at com.opticalable.geotracker.repository.DeviceDao$Proxy.queryDeviceInfoByOpticalCircuitName(Unknown Source) ~[na:na]
at com.opticalable.geotracker.controller.DeviceController.queryDeviceInfoByOpticalCircuitName(DeviceController.java:33) ~[classes/:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_332]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_332]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_332]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_332]
at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) ~[spring-web-5.3.24.jar:5.3.24]
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:150) ~[spring-web-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:117) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:808) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1071) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:964) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) ~[spring-webmvc-5.3.24.jar:5.3.24]
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:909) ~[spring-webmvc-5.3.24.jar:5.3.24]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:696) ~[tomcat-embed-core-9.0.69.jar:4.0.FR]
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) ~[spring-webmvc-5.3.24.jar:5.3.24]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:779) ~[tomcat-embed-core-9.0.69.jar:4.0.FR]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:227) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-embed-websocket-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) ~[spring-web-5.3.24.jar:5.3.24]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) ~[spring-web-5.3.24.jar:5.3.24]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) ~[spring-web-5.3.24.jar:5.3.24]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) ~[spring-web-5.3.24.jar:5.3.24]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) ~[spring-web-5.3.24.jar:5.3.24]
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:117) ~[spring-web-5.3.24.jar:5.3.24]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:177) ~[tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:135) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:360) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:399) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:891) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1784) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659) [tomcat-embed-core-9.0.69.jar:9.0.69]
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-9.0.69.jar:9.0.69]
at java.lang.Thread.run(Thread.java:750) [na:1.8.0_332]

``

@CorvusYe
Copy link
Collaborator

image

可以的话在这个位置运行一下这一行

nebulaPool.getConnection().ping()

@CorvusYe
Copy link
Collaborator

看报错日志,context 中的 nebulaPool 不为空,这行的断点是能进的,毕竟这是唯一一个能设置上下文 nebulaPool 的地方。
并且又是原生的连接池,
如果结果是 false,关注点可能还是要放在连接参数上。
如果结果是 true,则需要留意断点是否进了两次,导致后一次的参数值把前一个参数值覆盖了,这种情况之前issue有碰到过

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants