> On 11 Jun 2025, at 05:57, Sehen <
ohse...@gmail.com> wrote:
>
> Thanks for the answer Matthias Sohn.
>
> How does Gerrit work if HTTPD or SSHD Threads are added above the maxThreads setting at once?
> Is it queued and processed sequentially?
If you have more concurrent users than 2x the number of CPUs, you should be looking at a more scalable and elastic setup, such as K8s-Gerrit or AWS-Gerrit.
If you are on-premises, you should look at multiple Gerrit primaries in HA.
Lastly, if you are referring to a temporary burst of requests, they’ll be queued in the Jetty HTTP queue. You can configure how many of them should be queued.
> In my experience, when the limit is reached, the gerrit system seems to stop responding.
That’s not my experience, unless your Gerrit server is misconfigured, unless you reached the max capacity and then it is expected.
If you have a motorway of 4 lanes and they are all fully occupied, the montorway is stuck. How can that be different?
> What happens if you allocate 2 threads per CPU core = 96, and you get 200 threads at once?
200 - (2x96) = 8 threads will be queuened until an executor becomes available.
HTH
Luca.
>
> 2025년 6월 11일 수요일 오전 12시 50분 9초 UTC+9에 Matthias Sohn님이 작성:
> On Tue, Jun 10, 2025 at 5:27 PM Sehen <
ohse...@gmail.com> wrote:
> Hi,
> Recently, there have been a lot of slowness and stuttering on the Gerrit server, so we are reviewing it, but we don't know how to do it, so we are going to ask for your help.
> I would be grateful if you could review it together.
>
> Gerrit version: v3.5.2
> Situation :
> In recent months, Gerrit has been slowing down during business hours, or not being able to access the web or clone the code.
> I think the problem is the recent increase in the amount of access (httpd rest api calls), and the moment the connection is cut off also coincides with the time when the number of Metrics rest API calls increases.
> Action:
> I am testing by increasing and decreasing the values of httpd.maxThreads, minThreads, and maxQueued in gerrit.config.
> We have identified that a large part of the rest API calls are /a/changes/xxxx, so we are testing them by increasing or decreasing the changes, change_notes, and cache memoryLimit values.
> However, the phenomenon has not improved and the interruption phenomenon continues.
> Request:
> I ask for help to see if there is anything wrong with my settings or if there is something I need to do further.
>
> attached files is the values that monitor the metrics at the time of slow performance or no connection.
> My guess is that the httpd active threads value is small, but the moment it rises, and the moment it reaches the maxThreads value, it disconnects.
> How does Gerrit behave when the active threads count reaches maxThreads? I wonder if it queues additional requests and processes them sequentially, or if the system goes into an unresponsive waiting state.
>
>
> To view this discussion visit
https://groups.google.com/d/msgid/repo-discuss/f13515a0-8361-45bb-ad76-7b08e67c879dn%40googlegroups.com.