quarkusio/quarkus · critical · IOException
IOException(deploymentStatus)
Error message
IOException(deploymentStatus)
What it means
QuarkusCloudEventsFunction.accept throws an IOException whose message is the recorded bootstrap log (deploymentStatus) when the Quarkus application failed to start in the class's static initializer. The static block attempts to bootstrap the Quarkus app at function load time; if that fails, started stays false and every invocation reports the captured startup stack trace.
Source
Thrown at extensions/google-cloud-functions/runtime/src/main/java/io/quarkus/gcp/functions/QuarkusCloudEventsFunction.java:70
delegateClassLoader = Thread.currentThread().getContextClassLoader();
try {
Class<?> clazz = Class.forName(selectedDelegate, false, delegateClassLoader);
delegate = (CloudEventsFunction) Arc.container().instance(clazz).get();
} catch (ClassNotFoundException e) {
throw new RuntimeException(e);
}
}
}
public static void clearState() {
delegate = null;
delegateClassLoader = null;
}
@Override
public void accept(CloudEvent cloudEvent) throws Exception {
if (!started) {
throw new IOException(deploymentStatus);
}
// TODO maybe we can check this at static init
if (delegate == null) {
throw new IOException("We didn't found any CloudEventsFunction to run " +
"(or there is multiple one and none selected inside your application.properties)");
}
ClassLoader currentCl = Thread.currentThread().getContextClassLoader();
try {
Thread.currentThread().setContextClassLoader(delegateClassLoader);
delegate.accept(cloudEvent);
} finally {
Thread.currentThread().setContextClassLoader(currentCl);
}
}
}
View on GitHub (pinned to e1c734241f)
Solutions
- Read the IOException message: it contains the full bootstrap stack trace — fix the root startup failure it reports
- Run the function locally with the Quarkus dev/uber-jar mode to reproduce and see the startup error directly
- Validate all quarkus.* config properties and that required beans can be created
- Verify the deployment is an uber-jar built by the quarkus google-cloud-functions integration
Defensive patterns
Strategy: validation
Validate before calling
// validate config and startup before invoking the function locally ./mvnw package && java -jar target/function-function.jar // observe bootstrap logs # in tests: Assertions.assertTrue(QuarkusCloudEventsFunction.started, () -> deploymentStatus)
Try / catch
try {
function.accept(cloudEvent);
} catch (IOException e) {
if (e.getMessage().contains("Quarkus bootstrap failed")) {
LOG.error("Quarkus failed to start; bootstrap log:\n" + e.getMessage());
} else throw e;
} Prevention
- Always run the uber-jar locally with the Functions Framework before deploying
- Fail fast in CI on startup exceptions (they are only logged into deploymentStatus otherwise)
- Validate quarkus.* config in CI with quarkus:build
- Avoid per-invocation diagnostics: capture startup logs from the first cold start
When it happens
Trigger: Any exception during static-init bootstrap of io.quarkus.runner.ApplicationImpl (e.g. failed CDI init, bad configuration, missing bean) followed by a CloudEvent invocation reaching accept().
Common situations: Invalid quarkus.* configuration values, database/dependency connection failures at startup, bean creation failures, or running the function outside the GCP packaging model so bootstrap classes are missing.
Related errors
- IOException(deploymentStatus)
- IOException(deploymentStatus)
- RuntimeException(e)
- We didn't found any CloudEventsFunction to run (or there is
- Json object ended without }
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/2aef43e307cc8435.
Report an issue: GitHub.