renovatebot / renovate

Home of the Renovate CLI: Cross-platform Dependency Automation by Mend.io
https://mend.io/renovate
GNU Affero General Public License v3.0
17.55k stars 2.3k forks source link

File match scan got slow since version #19937

Closed mszalbach closed 1 year ago

mszalbach commented 1 year ago

How are you running Renovate?

Self-hosted

If you're self-hosting Renovate, tell us what version of Renovate you run.

34.106.0

If you're self-hosting Renovate, select which platform you are using.

Renovate full image on Linux Docker against a Bitbucket Server

If you're self-hosting Renovate, tell us what version of the platform you run.

Renovate image: renovate/renovate:34.106.0 Docker version 20.10.23, build 7155243 BitbucketServer 7.13.7

Was this something which used to work for you, and then stopped?

It used to work, and then stopped

Describe the bug

Renovate got slow while scanning for file match. This change happend somewhere between version 34.100.2(trying to pinpoint the excact version) and 34.102.7. It is still slow with the version 34.106.0.

From Tests with github platform against a glassfish fork I would say the problem starts occuring with renovate/renovate:34.102.6

For a single project the time for all file match checks increased from around 30 seconds to 3 minutes.

Relevant debug logs

Logs ``` [2023-01-20T09:23:25.257Z] DEBUG: Using RE2 as regex engine [2023-01-20T09:23:29.453Z] DEBUG: Parsing configs [2023-01-20T09:23:29.453Z] DEBUG: Checking for config file in /usr/src/app/config.js [2023-01-20T09:23:29.453Z] DEBUG: File config [2023-01-20T09:23:29.453Z] "config": { [2023-01-20T09:23:29.453Z] "platform": "bitbucket-server", [2023-01-20T09:23:29.453Z] "endpoint": "https://git.ivu-ag.com", [2023-01-20T09:23:29.453Z] "onboardingConfig": {"extends": ["config:base"]}, [2023-01-20T09:23:29.453Z] "onboarding": true, [2023-01-20T09:23:29.453Z] "allowedPostUpgradeCommands": [".*"], [2023-01-20T09:23:29.453Z] "regexManagers": [ [2023-01-20T09:23:29.453Z] { [2023-01-20T09:23:29.453Z] "fileMatch": ["^\\.copier-version$"], [2023-01-20T09:23:29.453Z] "matchStrings": [ [2023-01-20T09:23:29.453Z] "\\s+(?\\S+)\\s*#\\s*datasource=(?\\S+)\\s+template=(?