Using SonarQube Server Enterprise Edition v2025.2, trying to get projects to automatically be included in my portfolio based on Regex expression from the project key, nothing is returned.
Even using the example expression in the dialog box “A valid regular expression, eg. “.*Business” to match project names or keys that end with “Business”.” changing the word business to a word that I know ends a project key, does not generate any matches.
I’ve tried using expressions from regex101 that generate matches there, just not in the portfolio definition page.
FYI, your version is past EOL. You should update to either the latest version or the current LTA (long-term active version) at your earliest convenience. Your update path is:
Hi Colin, thanks for getting back to me. Yes I’m aware that we are not up to date, but it’s a large company and updates are not easy to get scheduled. We are at least within the LTA version, so I would expect this to be working.
I have tried to recompute after everything I’ve tried and still nothing populates.
And here’s the regex expression not generating any matches (but it does in regex101.com). This is after a recompute. I’ve also tried variations of this (in quotes, optimized for Java, etc) and it never picks anything up:
With your original regex, com.nice.lib-cxia-utils*. would match strings like com.nice.lib-cxia-utilsssssss (* allows repeating the character before it, here s) and com.nice.lib-cxia-utilsssssssa (. alone matches any character, once).
Switching to com.nice.lib-cxia-utils.* ensures you match any string starting with com.nice.lib-cxia-utils followed by anything (any character, any number of times). For even more precision, you can use com[.]nice[.]lib-cxia-utils.* to match only the literal periods.