Hi all, i'm troubleshooting an scenario that happens only when I'm looking for straight numbers (treated always as strings).
Looks like my searh elements are getting nested somehow and when try to have the json query, I'm getting EPiServer.Find.MaxSerializationDepthExceededException
The following query is being created as per the next code.
var searchResultList = searchRequests.Select(x => new Tuple<SearchRequestBody, Action<SearchCommand>>(x.Item1.RequestBody, x.Item1.CommandAction));
List<SearchResults<JObject>> list = multiSearch.Client.MultiSearch<JObject>(searchResultList, null).ToList<SearchResults<JObject>>();
here is the big nested json as result, the one who raises the expection above.
It only happens with certain numeric codes, not with non existen words or numbers or anything else.
"size":5,"query":{"filtered":{"query":{"filtered":{"query":{"function_score":{"query":{"custom_filters_score":{"query":{"filtered":{"query":{"bool":{"should":[
{"bool":{"should":[
{"bool":{"should":[
{"bool":{"should":[
{"bool":{"should":[
{"query_string":{"fields":["_all"
],"query":701200522,"analyzer":"synonym"
}
},
{"constant_score":{"filter":{"or":[
{"ids":null
}
]
}
}
}
]
}
}
]
}
}
]
}
}
]
}
}
]
}
}
}
}
}
}
}
}
}
}
}
}
}