Supporting existing code for a search on grants. The issue is the client is not able to see new grants in the search. It seems like the number of grants is greater than the ability of the SearchHandler to return. It's using a Lucene index. So this query.
var grantQueryResults = SearchHandler.Instance.GetSearchResults(query, 1, maxResults) //GET ALL .IndexResponseItems .Where(x => (x.Culture.Equals(culture) || string.IsNullOrEmpty(x.Culture)) && !x.ItemType.Contains(unifiedDirectoryType.FullName)) .OrderByDescending(x => x.Created) .ToList();
If I make the variable maxResults > 1000, the results return zero results. At 1000, it returns exactly 1000 results.
The previous developer threw the entire results into cache where they were queried later. Is there any way to increase that 1000 limit to get those newer records? Or do I need to rethink how the queries are executed.
Supporting existing code for a search on grants. The issue is the client is not able to see new grants in the search. It seems like the number of grants is greater than the ability of the SearchHandler to return. It's using a Lucene index. So this query.
var grantQueryResults = SearchHandler.Instance.GetSearchResults(query, 1, maxResults) //GET ALL
.IndexResponseItems
.Where(x =>
(x.Culture.Equals(culture) || string.IsNullOrEmpty(x.Culture))
&& !x.ItemType.Contains(unifiedDirectoryType.FullName))
.OrderByDescending(x => x.Created)
.ToList();
If I make the variable maxResults > 1000, the results return zero results. At 1000, it returns exactly 1000 results.
The previous developer threw the entire results into cache where they were queried later. Is there any way to increase that 1000 limit to get those newer records? Or do I need to rethink how the queries are executed.