[PR #7] [MERGED] Custom max number of goroutine #19

Closed
opened 2026-02-16 10:23:52 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-gitea/git/pull/7
Author: @thibaultmeyer
Created: 11/12/2016
Status: Merged
Merged: 11/12/2016
Merged by: @thibaultmeyer

Base: masterHead: feature/25-number-goroutine


📝 Commits (1)

  • 2bfc164 Can set a custom max number of goroutine

📊 Changes

1 file changed (+18 additions, -5 deletions)

View changed files

📝 tree_entry.go (+18 -5)

📄 Description

Currently, the number of goroutine is hard-coded to 10. It is not efficient, by exemple, with 2 core CPU or with 16 core- CPU.

This pull request add ability to set the maximum number of goroutine allowed on the function GetCommitsInfo (issue #25). If the given number is equal of lower than 0, the function runtime.NumCPU() will be used.

Later, if this PR is accepted, user will be able to set this max number of goroutine directly from Gitea app.ini configuration file.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-gitea/git/pull/7 **Author:** [@thibaultmeyer](https://github.com/thibaultmeyer) **Created:** 11/12/2016 **Status:** ✅ Merged **Merged:** 11/12/2016 **Merged by:** [@thibaultmeyer](https://github.com/thibaultmeyer) **Base:** `master` ← **Head:** `feature/25-number-goroutine` --- ### 📝 Commits (1) - [`2bfc164`](https://github.com/go-gitea/git/commit/2bfc164517885b548ce84486a4ccb1c6f78d6f80) Can set a custom max number of goroutine ### 📊 Changes **1 file changed** (+18 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `tree_entry.go` (+18 -5) </details> ### 📄 Description Currently, the number of goroutine is hard-coded to 10. It is not efficient, by exemple, with 2 core CPU or with 16 core- CPU. This pull request add ability to set the maximum number of goroutine allowed on the function `GetCommitsInfo` (issue #25). If the given number is equal of lower than 0, the function `runtime.NumCPU()` will be used. Later, if this PR is accepted, user will be able to set this max number of goroutine directly from Gitea `app.ini` configuration file. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 10:23:52 -05:00
yindo closed this issue 2026-02-16 10:23:52 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: go-gitea/git#19