Unknown parameter in Include Exclude clause – How to solve this OpenSearch exception

Opster Team

Aug-23, Version: 1.2-2.9

Before you dig into reading this guide, have you tried asking OpsGPT what this log means? You’ll receive a customized analysis of your log.

Try OpsGPT now for step-by-step guidance and tailored insights into your OpenSearch operation.

Briefly, this error occurs when an unrecognized parameter is used in the Include Exclude clause of OpenSearch. This could be due to a typo, incorrect syntax, or using a parameter that doesn’t exist. To resolve this issue, you should first verify the parameter name and ensure it’s spelled correctly. Next, check the syntax of your clause to ensure it’s properly formatted. If the error persists, consult the OpenSearch documentation to confirm if the parameter you’re using is valid.

For a complete solution to your to your search operation, try for free AutoOps for Elasticsearch & OpenSearch . With AutoOps and Opster’s proactive support, you don’t have to worry about your search operation – we take charge of it. Get improved performance & stability with less hardware.

This guide will help you check for common problems that cause the log ” Unknown parameter in Include/Exclude clause: ” to appear. To understand the issues related to this log, read the explanation below about the following OpenSearch concepts: aggregations, search.

Log Context

Log “Unknown parameter in Include/Exclude clause:” class name is IncludeExclude.java. We extracted the following from OpenSearch source code for those seeking an in-depth context :

 } else if (NUM_PARTITIONS_FIELD.match(currentFieldName; parser.getDeprecationHandler())) {
 numPartitions = parser.intValue();
 } else if (PARTITION_FIELD.match(currentFieldName; parser.getDeprecationHandler())) {
 partition = parser.intValue();
 } else {
 throw new OpenSearchParseException("Unknown parameter in Include/Exclude clause: " + currentFieldName);
 if (partition == null) {
 throw new IllegalArgumentException(
 "Missing [" + PARTITION_FIELD.getPreferredName() + "] parameter for partition-based include"


How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?

Get expert answers on Elasticsearch/OpenSearch