Caused by: java.lang.RuntimeException: Request cannot be executed; I/O reactor status: STOPPED
at org.elasticsearch.client.RestClient.extractAndWrapCause(RestClient.java:857)
at org.elasticsearch.client.RestClient.performRequest(RestClient.java:259)
at org.elasticsearch.client.RestClient.performRequest(RestClient.java:246)
at org.elasticsearch.client.RestHighLevelClient.internalPerformRequest(RestHighLevelClient.java:1613)
at org.elasticsearch.client.RestHighLevelClient.performRequest(RestHighLevelClient.java:1583)
at org.elasticsearch.client.RestHighLevelClient.performRequestAndParseEntity(RestHighLevelClient.java:1553)
at org.elasticsearch.client.RestHighLevelClient.search(RestHighLevelClient.java:1069)
at com.deyatech.esutil.service.impl.ElasticSearchServiceImpl.selectDataByESQueryJSON(ElasticSearchServiceImpl.java:581)
at com.deyatech.esutil.service.impl.ElasticSearchServiceImpl.searchData(ElasticSearchServiceImpl.java:548)
at com.deyatech.reception.service.impl.InfoTemplateEsServiceImpl.getElaticsearchResult(InfoTemplateEsServiceImpl.java:251)
at com.deyatech.reception.service.impl.InfoTemplateEsServiceImpl.getTemplateListView(InfoTemplateEsServiceImpl.java:120)
at com.deyatech.reception.service.impl.InfoTemplateServiceImpl.getTemplateListView(InfoTemplateServiceImpl.java:221)
at com.deyatech.reception.service.impl.InfoTemplateServiceImpl$$FastClassBySpringCGLIB$$aadf779.invoke(<generated>)
at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:771)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:749)
at org.springframework.cache.interceptor.CacheInterceptor.lambda$invoke$0(CacheInterceptor.java:53)
at org.springframework.cache.interceptor.CacheAspectSupport.invokeOperation(CacheAspectSupport.java:366)
at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:421)
at org.springframework.cache.interceptor.CacheAspectSupport.execute(CacheAspectSupport.java:346)
at org.springframework.cache.interceptor.CacheInterceptor.invoke(CacheInterceptor.java:61)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:749)
at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:691)
at com.deyatech.reception.service.impl.InfoTemplateServiceImpl$$EnhancerBySpringCGLIB$$6d755bd7.getTemplateListView(<generated>)
at com.deyatech.reception.thymeleaf.InfoDataExpressionObject.getInfoList(InfoDataExpressionObject.java:47)
at sun.reflect.GeneratedMethodAccessor1001.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at ognl.OgnlRuntime.invokeMethod(OgnlRuntime.java:902)
at ognl.OgnlRuntime.callAppropriateMethod(OgnlRuntime.java:1547)
... 113 common frames omitted
Caused by: java.lang.IllegalStateException: Request cannot be executed; I/O reactor status: STOPPED
at org.apache.http.util.Asserts.check(Asserts.java:46)
at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase.ensureRunning(CloseableHttpAsyncClientBase.java:90)
at org.apache.http.impl.nio.client.InternalHttpAsyncClient.execute(InternalHttpAsyncClient.java:123)
at org.elasticsearch.client.RestClient.performRequest(RestClient.java:255)
... 143 common frames omitted

github已提的问题

https://github.com/elastic/elasticsearch/issues/42133

https://github.com/elastic/elasticsearch/issues/45115

https://github.com/elastic/elasticsearch/issues/49124

https://github.com/elastic/elasticsearch/issues/39946

一些可以尝试的方法来解决问题

1、After some debugging and configuration tuning, I found that the exception was caused by too many concurrent ElasticSearch clients. After I reduce the number of concurrent clients, the exception is gone.
减少客户端的数量,使用的地方都注入。

2、 I'm using the client at scheduled method, so every invocation is started in new thread. The client has been injected to the service and never closed. Seems that is the reason of exception in my case. I changed my implementation so a new client is created at every thread when it is needed and closes in the end of method. That fixed the issue.
每次使用都新创建客户端,用完后关闭。

3、自己构建 RestHighLevelClient 使用 HttpComponents,链接STOP时重新构造客户端

【ElasticSearch】异常 Request cannot be executed; I/O reactor status: STOPPED的更多相关文章

  1. Java访问Elasticsearch报错Request cannot be executed; I/O reactor status: STOPPED

    简介 使用ES过程中遇到一个Request cannot be executed; I/O reactor status: STOPPED 的异常,大概意思是和server端的连接异常终止了.开始以为 ...

  2. ElasticSearch异常归纳(能力工场小马哥)

    异常1: can not run elasticsearch as root [WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [node-2] ...

  3. 异常System.Web.HttpException (0x80004005): Server cannot set status after HTTP headers have been sent.

    在用mvc 的AuthorizeAttribute做身份验证,重写HandleUnauthorizedRequest方法,在Application_Error方法里出现异常System.Web.Htt ...

  4. docker启动elasticsearch异常Failed to create node environment(解决)

    异常说是创建节点环境失败,操作/usr/share/elasticsearch/data/nodes的IO错误,尝试给此目录添加读写权限后,依旧没什么**用,灵机一动是不是挂载目录没有权限导致的? c ...

  5. iOS 使用AFNetworking遇到异常 Request failed: unacceptable content-type: text/html

    错误日志是: Error Domain=com.alamofire.error.serialization.response Code=-1016 "Request failed: unac ...

  6. 解决linux下root运行Elasticsearch异常

    如果以root身份运行将会出现以下问题 root@yxjay:/opt/elasticsearch-2.3.5/bin# ./elasticsearchException in thread &quo ...

  7. Logstash连接Elasticsearch异常

    1.背景 elasticsearch集群默认配置启动ok,logstash连接向里面发数据ok. 2.出现问题 修改elasticsearch.yml中的cluster.name,改为 esabc 然 ...

  8. elasticsearch异常问题 discovery.seed_hosts, discovery.seed_providers, cluster.initial_master_nodes] must be configured

    本文使用环境  centos7.x   elasticsearch7.6.2   JDK1.8 错误:文件权限不足      [1]: max file descriptors [4096] for ...

  9. 【异常】微博生成短链异常{"request":"/2/short_url/shorten.json","error_code":"10014","error":"Insufficient app permissions!"}

    一.之前的调用方式 这种方式用了大约有一年时间,之前没有问题,但是2019-8-28号突然不行了,可能是由于微博对该接口的调用做了限制.不允许通过传递source参数的方式进行请求 该接口微博API文 ...

随机推荐

  1. 搭建内网Yum源

    搭建内网yum源 阅读(2,238) 一:因内网服务器 众多,当统一安装一些比较大的rpm的时候全部从外网下载就比较慢,而且还占用了一定的出口流量,因此在内网部署了一台yum服务器,将阿里云的epel ...

  2. Linux系统分区及挂载点

    一.关于Linux的分区情况 虽然硬盘分区表中最多能存储四个分区,但我们实际使用时一般只分为两个分区,一个是主分区(Primary Partion)一个是扩展分区(extended partition ...

  3. XML名命空间

    XML的名命空间就类似于java的包,命名空间定义:xmlns:***="URI",默认命名空间定义:xmlns="URI" 引号中的URl内容用来唯一标识命名 ...

  4. 【力扣】922. 按奇偶排序数组 II

    给定一个非负整数数组 A, A 中一半整数是奇数,一半整数是偶数. 对数组进行排序,以便当 A[i] 为奇数时,i 也是奇数:当 A[i] 为偶数时, i 也是偶数. 你可以返回任何满足上述条件的数组 ...

  5. 【力扣】有序矩阵中第K小的元素

    给定一个 n x n 矩阵,其中每行和每列元素均按升序排序,找到矩阵中第 k 小的元素.请注意,它是排序后的第 k 小元素,而不是第 k 个不同的元素. 示例: matrix = [ [ 1, 5, ...

  6. 培训班输出的大量学员,会对IT行业产生哪些影响?

    先说下会有哪些影响呢?   1 可能也就是些大城市的,规模比较大的,口碑比较好的培训学校输出的码农才能入行,而且能做长久.一些线上的所谓培训机构,或者小城市的培训学校,输出的能入行的码农,其实规模很有 ...

  7. 【死磕Java并发】—–深入分析volatile的实现原理

    通过前面一章我们了解了synchronized是一个重量级的锁,虽然JVM对它做了很多优化,而下面介绍的volatile则是轻量级的synchronized.如果一个变量使用volatile,则它比使 ...

  8. Spring MVC环境搭建和配置

    1. 创建Dynamic web project 2. 修改WEB-INF/web.xml,内容如下: <?xml version="1.0" encoding=" ...

  9. [BUUCTF]PWN——babyfengshui_33c3_2016

    babyfengshui_33c3_2016 附件 步骤: 例行检查,32位程序,开启了cannary和nx 本地运行一下看看大概的情况,熟悉的堆的菜单布局 32位ida载入,看main函数 add ...

  10. box-shadow(盒子阴影)

    box-shadow 属性可以设置一个或多个下拉阴影的框 可以在同一个元素上设置多个阴影效果,并用逗号将他们分隔开.该属性可设置的值包括阴影的X轴偏移量.Y轴偏移量.模糊半径.扩散半径和颜色. 语法: ...