quarkusio/quarkus · error · UncheckedIOException

java.io.IOException wrapped in UncheckedIOException (no own

Error message

java.io.IOException wrapped in UncheckedIOException (no own message)

What it means

While probing archive paths to decide whether an archive is a bean archive (possiblyBeanArchive), an IOException from path traversal/walking is rethrown wrapped in UncheckedIOException. The wrapper has no message of its own; the cause carries the original IOException details.

Source

Thrown at extensions/arc/deployment/src/main/java/io/quarkus/arc/deployment/BeanArchiveProcessor.java:255

                                || text.contains("bean-discovery-mode=\"none\"")) {
                            return false;
                        }

                        if (text.contains("bean-discovery-mode='all'")
                                || text.contains("bean-discovery-mode=\"all\"")) {

                            if (!knownCompatibleBeanArchives.isKnownCompatible(archive.getKey(),
                                    KnownCompatibleBeanArchiveBuildItem.Reason.BEANS_XML_ALL)) {
                                LOGGER.warnf("Detected bean archive with bean discovery mode of 'all', "
                                        + "this is not portable in CDI Lite and is treated as 'annotated' in Quarkus! "
                                        + "Path to beans.xml: %s",
                                        archive.getResolvedDependency() != null
                                                ? archive.getResolvedDependency().toCompactCoords() + ":" + pathVisit.getPath()
                                                : pathVisit.getPath());
                            }
                        }
                    } catch (IOException e) {
                        throw new UncheckedIOException(e);
                    }

                    return true;
                });
            }
            return result;
        });
    }

    private boolean isApplicationArchiveExcluded(ArcConfig config, List<ExcludeDependencyBuildItem> excludeDependencyBuildItems,
            ApplicationArchive archive) {
        if (archive.getKey() != null) {
            final ArtifactKey key = archive.getKey();
            for (IndexDependencyConfig excludeDependency : config.excludeDependency().values()) {
                if (archiveMatches(key, excludeDependency.groupId(), excludeDependency.artifactId(),
                        excludeDependency.classifier())) {
                    return true;
                }

View on GitHub (pinned to e1c734241f)

Solutions

  1. Delete the corrupted artifact from the local repository (~/.m2/repository/<group>/<artifact>) and rebuild so Maven re-downloads it
  2. Run mvn -U to force refresh of dependencies
  3. Inspect the cause chain (e.getCause()) to identify the exact file and IO problem
  4. Check filesystem permissions/disk space on the build machine

Example fix

// shell: remove and re-fetch a broken jar
rm -rf ~/.m2/repository/com/acme/acme-lib/1.0.0
./mvnw -U clean install
Defensive patterns

Strategy: try-catch

Try / catch

try {
    quarkusApp.run(args);
} catch (UncheckedIOException e) {
    IOException cause = e.getCause();
    log.error("Archive scan failed: " + cause.getMessage(), cause); // inspect cause for the corrupt jar
}

Prevention

When it happens

Trigger: An IOException occurs while walking files/zip entries of a dependency archive during application index building — e.g. corrupt or unreadable jar, closed file handle, transient filesystem error, permission issues.

Common situations: Corrupted jar in the local Maven repository (~/.m2); build running in a container with a truncated dependency; file deleted between resolution and scan; network-mounted repo flakiness.

Related errors


AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05). Data as JSON: /api/errors/24536927905e7545. Report an issue: GitHub.