-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Slow performance (30+ seconds) when adding user to a group in large organization #19216
Comments
Could you provide logs? |
Given the code, I would say that's likely something on https://github.com/go-gitea/gitea/blob/e69b7a92ed/models/org_team.go#L969 . The more repos on a team, the more slow it would be due to the looping over all repos. |
Here the part of Logs:
|
@IT-AlexKor can you test latest state of #19227 ? |
@6543 sorry, but it may be complicated, because it's a single production instance... |
I have tested locally. Add member should be very fast, but I need to know if the result is right. Have no idea to optimize remove member from team. |
Description
Slow performance (7 minutes) on UI/API when adding/removing team in large organization (2000+ repos)
Steps to reproduce
Gitea Version
1.16.3
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
No response
Screenshots
No response
Git Version
2.21.0
Operating System
CentOS Linux 7 (Core)
How are you running Gitea?
APP_NAME = -ERASED-
RUN_USER = git
RUN_MODE = prod
[security]
INTERNAL_TOKEN = -ERASED-
INSTALL_LOCK = true
SECRET_KEY = -ERASED-
PASSWORD_HASH_ALGO = pbkdf2
DISABLE_GIT_HOOKS = false
[database]
DB_TYPE = postgres
HOST = -ERASED-
NAME = -ERASED-
USER = -ERASED-
PASSWD = -ERASED-
SCHEMA =
SSL_MODE = disable
CHARSET = utf8
PATH = /var/lib/gitea/data/gitea.db
LOG_SQL = false
[repository]
ROOT = /var/lib/gitea/data/gitea-repositories
[server]
SSH_DOMAIN = -ERASED-
DOMAIN = -ERASED-
HTTP_PORT = 3000
ROOT_URL = -ERASED-
DISABLE_SSH = false
SSH_PORT = 22
LFS_START_SERVER = true
LFS_JWT_SECRET = -ERASED-
OFFLINE_MODE = false
[lfs]
PATH = /var/lib/gitea/data/lfs
[mailer]
ENABLED = true
HOST = -ERASED-
FROM = -ERASED-
USER =
PASSWD =
[service]
REGISTER_EMAIL_CONFIRM = false
ENABLE_NOTIFY_MAIL = true
DISABLE_REGISTRATION = true
ALLOW_ONLY_EXTERNAL_REGISTRATION = false
ENABLE_CAPTCHA = false
REQUIRE_SIGNIN_VIEW = true
DEFAULT_KEEP_EMAIL_PRIVATE = false
DEFAULT_ALLOW_CREATE_ORGANIZATION = false
ENABLE_TIMETRACKING = false
DEFAULT_ENABLE_TIMETRACKING = false
NO_REPLY_ADDRESS = noreply.localhost
[picture]
DISABLE_GRAVATAR = false
ENABLE_FEDERATED_AVATAR = true
[openid]
ENABLE_OPENID_SIGNIN = false
ENABLE_OPENID_SIGNUP = false
[session]
PROVIDER = file
[log]
MODE = file,console
LEVEL = info
ROOT_PATH = /var/lib/gitea/log
ROUTER = console,file
[metrics]
ENABLED = true
[mirror]
MIN_INTERVAL = 1m
[indexer]
ISSUE_INDEXER_TYPE = elasticsearch
ISSUE_INDEXER_CONN_STR = http://-ERASED-
ISSUE_INDEXER_NAME = gitea_issues
ISSUE_INDEXER_PATH = indexers/issues.bleve
REPO_INDEXER_ENABLED = true
REPO_INDEXER_TYPE = elasticsearch
REPO_INDEXER_CONN_STR = http://-ERASED-
REPO_INDEXER_NAME = gitea_codes
REPO_INDEXER_PATH = indexers/repos.bleve
UPDATE_BUFFER_LEN = 20
MAX_FILE_SIZE = 1048576
REPO_INDEXER_INCLUDE =
REPO_INDEXER_EXCLUDE = resources/bin/**
STARTUP_TIMEOUT = 30s
[git.timeout]
MIGRATE = 1800
MIRROR = 600
Database
PostgreSQL
The text was updated successfully, but these errors were encountered: