{"record":{"id":"4ef0eda32b01a3b2","repo":"oracle/graal","slug":"this-vm-does-not-support-continuations","errorCode":null,"errorMessage":"This VM does not support continuations.","messagePattern":"This VM does not support continuations\\.","errorType":"exception","errorClass":"UnsupportedOperationException","httpStatus":null,"severity":"error","filePath":"espresso/src/org.graalvm.continuations/src/org/graalvm/continuations/Continuation.java","lineNumber":136,"sourceCode":"        return IS_SUPPORTED;\n    }\n\n    /**\n     * Creates a new suspended continuation, taking in an {@link ContinuationEntryPoint}.\n     *\n     * <p>\n     * To begin execution call the {@link Continuation#resume()} method. The entry point will be\n     * passed a {@link SuspendCapability capability object} allowing it to suspend itself.\n     *\n     * <p>\n     * The continuation will be serializable so long as the given {@link ContinuationEntryPoint} is\n     * serializable.\n     *\n     * @throws UnsupportedOperationException If this VM does not support continuation.\n     */\n    public static Continuation create(ContinuationEntryPoint continuationEntryPoint) {\n        if (!isSupported()) {\n            throw new UnsupportedOperationException(\"This VM does not support continuations.\");\n        }\n        return new ContinuationImpl(continuationEntryPoint);\n    }\n\n    /**\n     * Returns {@code true} if this continuation is able to be {@link #resume() resumed}.\n     * <p>\n     * A continuation is resumable if it is freshly created, or if it has been resumed then\n     * suspended.\n     * <p>\n     * A continuation that has {@link #isCompleted() finished executing} is not resumable.\n     * <p>\n     * A continuation that is being serialized will return {@code false}, until serialization\n     * completes.\n     */\n    public abstract boolean isResumable();\n\n    /**","sourceCodeStart":118,"sourceCodeEnd":154,"githubUrl":"https://github.com/oracle/graal/blob/a66e9ccd1d7bf2552883939aa0788dfd0e294aab/espresso/src/org.graalvm.continuations/src/org/graalvm/continuations/Continuation.java#L118-L154","documentation":"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.","triggerScenarios":"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.","commonSituations":"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.","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."],"exampleFix":"// before\nContinuation c = Continuation.create(entryPoint);\n\n// after\nif (!Continuation.isSupported()) {\n    throw new IllegalStateException(\"Continuations require Java on Truffle with java.Continuum=true\");\n}\nContinuation c = Continuation.create(entryPoint);","handlingStrategy":"validation","validationCode":"if (!Continuation.isSupported()) {\n    throw new IllegalStateException(\"Continuations need Java on Truffle with java.Continuum=true\");\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["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."],"tags":["continuations","unsupported-operation","graalvm","truffle","espresso","vm-config"],"backgroundTag":null,"analyzedSha":"a66e9ccd1d7bf2552883939aa0788dfd0e294aab","analyzedAt":"2026-08-14T13:58:47.161Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}