You are currently reviewing an older revision of this page.

DRAFT KB-[SP-6416] Expression search fails with "CdtQueryRequest" error

Symptoms

Searching by expression in /design/objects fails with the following error

  

Additionally, the following error appears in the application server log:

ERROR com.appiancorp.rest.shared.AppianExceptionMapper - Internal Server Error on REST API invocation. 

com.appiancorp.exceptions.LocalizedAppianRuntimeException$LocalizedAppianException: Expression evaluation error [evaluation ID = <EVALUATION_ID>] : Query failed [request=CdtQueryRequest{from=ObjectInfo (id=-10), timeZone=null, query=Query[Selection[uuid (show)], criteria[CdtSearch{field=expressions, searchQuery=753, searchType=prefix, isHighlightResults=true, startTag=<EE><89><95><EE><89><96>, endTag=<EE><89><95>, snippetLength=100}], PagingInfo[startIndex=0, batchSize=10000, sort=[Sort[#RELEVANCE# desc]]]]}, ES SearchRequest=SearchRequest{searchType=QUERY_THEN_FETCH, indices=[designer-objects-ia-7-5], indicesOptions=IndicesOptions[ignore_unavailable=false, allow_no_indices=true, expand_wildcards_open=true, expand_wildcards_closed=false, expand_wildcards_hidden=false, allow_aliases_to_multiple_indices=true, forbid_closed_indices=true, ignore_aliases=false, ignore_throttled=true], types=[], routing='null', preference='null', requestCache=null, scroll=null, maxConcurrentShardRequests=0, batchedReduceSize=512, preFilterShardSize=null, allowPartialSearchResults=null, localClusterAlias=null, getOrCreateAbsoluteStartMillis=-1, ccsMinimizeRoundtrips=true, source={"from":0,"size":10000,"query":{"bool":{"must":[{"bool":{"must":[{"match_phrase_prefix":{"expressions":{"query":"753","slop":0,"max_expansions":50,"boost":1.0}}}],"adjust_pure_negative":true,"boost":1.0}}],"filter":[{"term":{"_t":{"value":"DTObjectInfo","boost":1.0}}}],"adjust_pure_negative":true,"boost":1.0}},"version":true,"_source":{"includes":["uuid"],"excludes":[]},"sort":[{"_score":{"order":"desc"}}],"track_total_hits":2147483647,"highlight":{"pre_tags":["<EE><89><95><EE><89><96>"],"post_tags":["<EE><89><95>"],"fields":{"expressions":{"fragment_size":100}}}}}] (APNX-1-4198-000)

Cause

An object was found which exceeded the Search Server's maximum content size limit of 1,000,000 characters. Using objects with content size over 1,000,000 may cause issues.

Action

  1. Search the bottom of the stacktrace for mention of object UUID:
    Caused by: ElasticsearchException[Elasticsearch exception [type=illegal_argument_exception, reason=The length of [expressions] field of [<OBJECT_UUID>] doc of [designer-objects-ia-7-5] index has exceeded [1000000] - maximum allowed to be analyzed for highlighting. This maximum can be set by changing the [index.highlight.max_analyzed_offset] index level setting. For large texts, indexing with offsets or term vectors is recommended!]]
  2. Delete the object with matching UUID, or remove/reduce it's contents.

Affected Versions

This article applies to all versions of Appian.

Last Reviewed: February 2022