# In 6.6 broken indices.query.bool.max\_clause\_count configuring

**URL:** <https://discuss.elastic.co/t/in-6-6-broken-indices-query-bool-max-clause-count-configuring/170747>\
**Category:** Elasticsearch\
**Created:** [March 4, 2019, 2:58pm UTC](https://discuss.elastic.co/t/in-6-6-broken-indices-query-bool-max-clause-count-configuring/170747 "2019-03-04T14:58:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ra-coder](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@ra-coder](https://discuss.elastic.co/u/ra-coder)\
**Post date:** [March 4, 2019, 2:58pm UTC](https://discuss.elastic.co/t/in-6-6-broken-indices-query-bool-max-clause-count-configuring/170747/1 "2019-03-04T14:58:11Z")

</div>

after switch from 6.5 to 6.6 not working set up in `/etc/elasticsearch/elasticsearch.yml` of

`indices.query.bool.max_clause_count: 10000`

with many clause query i got next in log

```
...
        at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:41) [elasticsearch-6.6.1.jar:6.6.1]
        at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-6.6.1.jar:6.6.1]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_191]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_191]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_191]
Caused by: org.apache.lucene.search.BooleanQuery$TooManyClauses: maxClauseCount is set to 1024
        at org.apache.lucene.search.BooleanQuery$Builder.add(BooleanQuery.java:114) ~[lucene-core-7.6.0.jar:7.6.0 719cde97f84640faa1e3525690d262946571245f - nknize - 2018-12-07 14:44:20]
        at org.elasticsearch.index.query.BoolQueryBuilder.addBooleanClauses(BoolQueryBuilder.java:422) ~[elasticsearch-6.6.1.jar:6.6.1]
        at org.elasticsearch.index.query.BoolQueryBuilder.doToQuery(BoolQueryBuilder.java:385) ~[elasticsearch-6.6.1.jar:6.6.1]
        at org.elasticsearch.index.query.AbstractQueryBuilder.toQuery(AbstractQueryBuilder.java:104) ~[elasticsearch-6.6.1.jar:6.6.1]
        at org.elasticsearch.index.query.QueryShardContext.lambda$toQuery$2(QueryShardContext.java:308) ~[elasticsearch-6.6.1.jar:6.6.1]
        at org.elasticsearch.index.query.QueryShardContext.toQuery(QueryShardContext.java:320) ~[elasticsearch-6.6.1.jar:6.6.1]
...

```

but still have `"query":{"bool":{"max_clause_count":"10000"},` substring in  
`curl -X GET localhost:9200/_cluster/settings?include_defaults=true | grep max_clause_count`

---

<div class="post-metadata">

**Author:** ![ra-coder](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@ra-coder](https://discuss.elastic.co/u/ra-coder)\
**Post date:** [March 4, 2019, 3:05pm UTC](https://discuss.elastic.co/t/in-6-6-broken-indices-query-bool-max-clause-count-configuring/170747/2 "2019-03-04T15:05:51Z")

</div>

> [@ra-coder](#):
>
> max\_clause\_count

semes that there are alredy bug for this

> <https://github.com/elastic/elasticsearch/issues/39528>
>
> Hi there !
> 
> When i'm trying to index a percolate query (query string with a lo…t of OR clauses), the server fails with max\_clause\_count error :
> 
> \`\`\`
> "caused\_by": {
> "type": "too\_many\_clauses",
> "reason": "maxClauseCount is set to 1024"
> }
> \`\`\`
> 
> I raised the \`\`\`indices.query.bool.max\_clause\_count\`\`\` value in configuration, restarted, checked the /\_nodes entrypoint : 
> 
> \`\`\`
> "indices": {
> "query": {
> "bool": {
> "max\_clause\_count": "10240"
> }
> }
> }
> \`\`\`
> 
> But this parameter is ignored during percolate indexation... 
> 
> Thx
> 
> Version : \*\*6.6.1 (docker)\*\*

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 1, 2019, 3:05pm UTC](https://discuss.elastic.co/t/in-6-6-broken-indices-query-bool-max-clause-count-configuring/170747/3 "2019-04-01T15:05:52Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
