quarkusio/quarkus · warning · MultipleExtensionsFoundException
Multiple extensions found for keyword (no message; handled a
Error message
Multiple extensions found for keyword (no message; handled and reported as "Multiple extensions matching '${keyword}'" with the extension list) What it means
planInstallation throws MultipleExtensionsFoundException when a keyword matches more than one catalog extension and the keyword is not a wildcard pattern. It is handled upstream: the handler reports 'Multiple extensions matching <keyword>' with the candidate list instead of failing hard.
Source
Thrown at independent-projects/tools/devtools-common/src/main/java/io/quarkus/devtools/commands/handlers/AddExtensionsCommandHandler.java:154
for (Extension e : invocation.getExtensionsCatalog().getExtensions()) {
if (e.getArtifact().getKey().equals(artifactKey)) {
listed = List.of(e);
break;
}
}
//builder.addManagedExtension(new ArtifactCoords(artifactKey, null));
} else {
listed = listInternalExtensions(quarkusCore, keyword, catalog.getExtensions());
}
if (listed.isEmpty()) {
// No extension found for this keyword.
builder.addUnmatchedKeyword(keyword);
}
// If it's a pattern allow multiple results
// See https://github.com/quarkusio/quarkus/issues/11086#issuecomment-666360783
else if (listed.size() > 1 && !ExtensionPredicate.isPattern(keyword)) {
throw new MultipleExtensionsFoundException(keyword, listed);
}
for (Extension e : listed) {
final ArtifactCoords extensionCoords = e.getArtifact();
boolean managed = false;
ExtensionOrigin firstPlatform = null;
ExtensionOrigin preferredOrigin = null;
for (ExtensionOrigin origin : e.getOrigins()) {
if (!origin.isPlatform()) {
continue;
}
if (importedPlatforms.contains(origin.getBom())) {
managed = true;
builder.addManagedExtension(extensionCoords);
break;
}
if (preferredOrigin == null) {
if (preferredBoms.contains(origin.getBom())) {
preferredOrigin = origin;View on GitHub (pinned to e1c734241f)
Solutions
- Use the exact extension name or full GAV (groupId:artifactId)
- Use a wildcard pattern (e.g. quarkus-rest*) if multiple matches are intended
- Run the list command to inspect matching extensions before adding
- Update scripts to the new canonical names after upgrading Quarkus
Example fix
// before
invocation.extensions().add("rest");
// after
invocation.extensions().add("quarkus-rest-jackson"); Defensive patterns
Strategy: validation
Validate before calling
List<String> matches = catalog.getExtensions().stream()
.map(Extension::getArtifact).map(ArtifactCoords::getArtifactId)
.filter(id -> id.contains(keyword)).toList();
if (matches.size() > 1 && !keyword.contains("*")) throw new IllegalArgumentException("Ambiguous keyword '" + keyword + "': " + matches); Type guard
static boolean isUnambiguous(String keyword, List<String> ids) {
return ids.stream().filter(id -> id.contains(keyword)).count() <= 1 || ExtensionPredicate.isPattern(keyword);
} Try / catch
try { plan = handler.planInstallation(invocation, keywords); } catch (MultipleExtensionsFoundException e) { System.out.println("Pick one of: " + e.getListedExtensions()); } Prevention
- Always use full artifact ids or GAVs in scripts
- Check extension names after Quarkus upgrades (renames/splits)
- Use wildcard patterns intentionally, not by accident
- Preview matches with the list command before adding
When it happens
Trigger: Calling planInstallation (or extensionInstallPlan) with a keyword like 'rest' that matches several extensions (e.g. rest, rest-jackson, resteasy) and is not a '*' pattern.
Common situations: Typing a short or generic extension name in 'quarkus add extension'; scripts relying on partial names after a Quarkus version renamed/split extensions (e.g. resteasy-reactive -> quarkus-rest).
Related errors
- Failed to create project because of invalid extensions
- Failed to create project because of invalid extensions
- %s is marked @Record but does not inject an @Recorder object
- Unknown recorder constructor parameter: %s in recorder %s
- capabilityErrors.report()
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/7c61017f71a44cd1.
Report an issue: GitHub.