Change By: Steven Christou (27/Feb/14 11:32 PM)
Description: The current search box is very inefficient when checking for suggestions. When a user enters part of a username waiting for the autocomplete to finish, if there are a lot of users it can take a very long time.

While running a search in the search box I ran a quick thread dump to find out where the suggest was being stuck at and found:

Handling GET /jenkins/search/suggest : … state=RUNNABLE
    at java.lang.String$CaseInsensitiveComparator.compare(String.java:1170)
    at java.lang.String.compareToIgnoreCase(String.java:1220)
    at hudson.model.User$1.compare(User.java:397)
    at hudson.model.User$1.compare(User.java:395)
    at java.util.TimSort.mergeLo(TimSort.java:687)
    at java.util.TimSort.mergeAt(TimSort.java:483)
    at java.util.TimSort.mergeCollapse(TimSort.java:408)
    at java.util.TimSort.sort(TimSort.java:214)
    at java.util.TimSort.sort(TimSort.java:173)
    at java.util.Arrays.sort(Arrays.java:659)
    at java.util.Collections.sort(Collections.java:217)
    at hudson.model.User.getAll(User.java:395)
    at hudson.model.User$FullNameIdResolver.resolveCanonicalId(User.java:735)
    at hudson.model.User.get(User.java:326)
    at hudson.model.User.get(User.java:299)
    at hudson.model.User.get(User.java:354)
    at hudson.model.User.current(User.java:366)
    at hudson.search.UserSearchProperty.isCaseInsensitive(UserSearchProperty.java:26)
    at hudson.search.CollectionSearchIndex.suggest(CollectionSearchIndex.java:61)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:63)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:62)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:62)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:62)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:62)
    at hudson.search.UnionSearchIndex.suggest(UnionSearchIndex.java:63)
    at hudson.search.Search$Mode$2.find(Search.java:192)
    at hudson.search.Search.find(Search.java:343)
    at hudson.search.Search.suggest(Search.java:268)
    at hudson.search.Search.getSuggestions(Search.java:134)
    at hudson.search.Search.doSuggest(Search.java:117)
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to