oracle/graal · error · UnsupportedOperationException
This VM does not support continuations.
Error message
This VM does not support continuations.
What it means
UnsupportedOperationException from Continuation.create when the current JVM cannot provide continuations. The org.graalvm.continuations API is only functional on Java on Truffle (Espresso) with the java.Continuum option enabled; on a regular JVM or without the flag, isSupported() is false and creation is refused.
Source
Thrown at espresso/src/org.graalvm.continuations/src/org/graalvm/continuations/Continuation.java:136
return IS_SUPPORTED;
}
/**
* Creates a new suspended continuation, taking in an {@link ContinuationEntryPoint}.
*
* <p>
* To begin execution call the {@link Continuation#resume()} method. The entry point will be
* passed a {@link SuspendCapability capability object} allowing it to suspend itself.
*
* <p>
* The continuation will be serializable so long as the given {@link ContinuationEntryPoint} is
* serializable.
*
* @throws UnsupportedOperationException If this VM does not support continuation.
*/
public static Continuation create(ContinuationEntryPoint continuationEntryPoint) {
if (!isSupported()) {
throw new UnsupportedOperationException("This VM does not support continuations.");
}
return new ContinuationImpl(continuationEntryPoint);
}
/**
* Returns {@code true} if this continuation is able to be {@link #resume() resumed}.
* <p>
* A continuation is resumable if it is freshly created, or if it has been resumed then
* suspended.
* <p>
* A continuation that has {@link #isCompleted() finished executing} is not resumable.
* <p>
* A continuation that is being serialized will return {@code false}, until serialization
* completes.
*/
public abstract boolean isResumable();
/**View on GitHub (pinned to a66e9ccd1d)
Solutions
- Run the application on Java on Truffle with the java.Continuum option enabled (e.g. component option java.Continuum=true / --vm.Xflag:+Continuum as documented for your GraalVM version).
- Guard creation with if (Continuation.isSupported()) and provide a thread-based or async fallback path.
- Skip continuation tests on JVMs where isSupported() is false (JUnit assumption).
- Verify the runtime at startup and fail fast with a clear message instead of deep in execution.
Example fix
// before
Continuation c = Continuation.create(entryPoint);
// after
if (!Continuation.isSupported()) {
throw new IllegalStateException("Continuations require Java on Truffle with java.Continuum=true");
}
Continuation c = Continuation.create(entryPoint); Defensive patterns
Strategy: validation
Validate before calling
if (!Continuation.isSupported()) {
throw new IllegalStateException("Continuations need Java on Truffle with java.Continuum=true");
} Prevention
- Probe isSupported() at application startup and fail fast with guidance.
- Pin CI/test runtimes to Java on Truffle with java.Continuum enabled.
- Keep a non-continuation fallback path for standard JVMs.
When it happens
Trigger: Calling Continuation.create(entryPoint) on a stock HotSpot JVM, on GraalVM Native Image, or on Java on Truffle launched without --vm.Xflag java.Continuum=true.
Common situations: Library developed on Java on Truffle but unit-tested on a plain JDK via Maven/Gradle; CI pipelines not using the Truffle JVM; deploying the continuation-based code to a standard runtime in production.
Related errors
- Continuations must be run on the Java on Truffle JVM with th
- This VM does not support continuations.
- You can't resume an already executing continuation.
- This continuation has already completed successfully.
- This continuation has failed and must be discarded.
AI-assisted analysis of oracle/graal@a66e9ccd1d (2026-08-14).
Data as JSON: /api/errors/4ef0eda32b01a3b2.
Report an issue: GitHub.