

On 21 Feb 2023, at 08:41, natali...@gmail.com <natali...@gmail.com> wrote:Hi,In my case, it's a side effect from this change.The change would run match for each predicate(i.e. file:<query>, message:<query>,etc.) instead of using the search results from index.That would require a lot of read from git repository to get change file list or commit message, hence slows down the query.I end up reverting the change to restore the performance.
--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/e9ad504a-94fc-4721-b8ad-c97ebf099fddn%40googlegroups.com.
On 21 Feb 2023, at 08:41, natali...@gmail.com <natali...@gmail.com> wrote:Hi,In my case, it's a side effect from this change.The change would run match for each predicate(i.e. file:<query>, message:<query>,etc.) instead of using the search results from index.That would require a lot of read from git repository to get change file list or commit message, hence slows down the query.I end up reverting the change to restore the performance.Thanks for reporting this: can you please raise an issue with the steps to reproduce the issue?
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/51C7824C-B272-45B4-8D4E-DB1CA1268072%40gmail.com.
Hi
We upgraded Gerrit from v2.15.22 to v3.4.1.
Sometimes, the filter function for the repository search gets slowly.
We executed the query every 1 second and showed the results graphically.
Horizontal axis: time the query is executed
Vertical axis: response time outputted in http_log
We confirmed that the response time got slowly every few hours.
We referred about response time from the following document.
https://gerrit-documentation.storage.googleapis.com/Documentation/3.4.1/logs.html
The below log in http_log showed the query took 1,139,998 milliseconds to response.
xxx.xxx.xxx.xxx [HTTP-224556] - xxxxx [2023-01-26T11:18:46.671+09:00] "GET /a/projects/?query=platform HTTP/1.1" 200 32768 1139998 - "curl/7.58.0" 6260 4480 2983452888
We checked thread dump when the query was slower, we found the processing of WindowCache.removeAll was "wait"
"HTTP GET /a/projects/?query=platform (0048800102 from 10.26.24.7)" #224556 prio=5 os_prio=0 cpu=67057.77ms elapsed=58111.20s tid=0x00007e930c006000 nid=0x6614 waiting for monitor entry [0x00007e93dbaf7000]
./jstack.out_20230126_110453: java.lang.Thread.State: BLOCKED (on object monitor)
at org.eclipse.jgit.lib.RepositoryCache.openRepository(RepositoryCache.java:242)
- waiting to lock <0x00007ea262bb85a0> (a org.eclipse.jgit.lib.RepositoryCache$Lock)
"JGit-WorkQueue" #37 daemon prio=5 os_prio=0 cpu=129145320.78ms elapsed=769921.60s tid=0x00007e9c8c1aa800 nid=0x77b7 runnable [0x00007e9cdd281000]
java.lang.Thread.State: RUNNABLE
at org.eclipse.jgit.internal.storage.file.WindowCache.removeAll(WindowCache.java:718)
at org.eclipse.jgit.internal.storage.file.WindowCache.purge(WindowCache.java:398)
at org.eclipse.jgit.internal.storage.file.Pack.close(Pack.java:286)
at org.eclipse.jgit.internal.storage.file.PackDirectory.close(PackDirectory.java:102)
at org.eclipse.jgit.internal.storage.file.ObjectDirectory.close(ObjectDirectory.java:199)
at org.eclipse.jgit.lib.Repository.doClose(Repository.java:967)
at org.eclipse.jgit.lib.RepositoryCache.unregisterAndCloseRepository(RepositoryCache.java:276)
- locked <0x00007ea262bb85a0> (a org.eclipse.jgit.lib.RepositoryCache$Lock)
We have not confirmed this behavior in Gerrit 2.15.22.
Does anyone know why the filter function for repository search gets slow in Gerrit 3.4.1?
Is there any solution to fix this issue?
--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/291a80bb-2c20-4b8b-b0b2-9a670a9ef719n%40googlegroups.com.

