quarkusio/quarkus · error · java.lang.IllegalStateException
Not a resolver:
Error message
Not a resolver:
What it means
EngineProducer.createResolver loads the class named by quarkus.qute.resolver.<n> class-name config and casts it to io.quarkus.qute.Resolver. If the class loads but does not implement Resolver, startup fails with this error. It guards the reflective instantiation of user-supplied resolvers.
Source
Thrown at extensions/qute/runtime/src/main/java/io/quarkus/qute/runtime/EngineProducer.java:366
@Produces
@ApplicationScoped
Engine getEngine() {
return engine;
}
void onShutdown(@Observes ShutdownEvent event) {
// Make sure to clear the Qute cache
Qute.clearCache();
}
private Resolver createResolver(String resolverClassName) {
try {
Class<?> resolverClazz = Thread.currentThread()
.getContextClassLoader().loadClass(resolverClassName);
if (Resolver.class.isAssignableFrom(resolverClazz)) {
return (Resolver) resolverClazz.getDeclaredConstructor().newInstance();
}
throw new IllegalStateException("Not a resolver: " + resolverClassName);
} catch (InstantiationException | IllegalAccessException | ClassNotFoundException | IllegalArgumentException
| InvocationTargetException | NoSuchMethodException | SecurityException e) {
throw new IllegalStateException("Unable to create resolver: " + resolverClassName, e);
}
}
private TemplateGlobalProvider createGlobalProvider(String initializerClassName) {
try {
Class<?> initializerClazz = Thread.currentThread()
.getContextClassLoader().loadClass(initializerClassName);
if (TemplateGlobalProvider.class.isAssignableFrom(initializerClazz)) {
return (TemplateGlobalProvider) initializerClazz.getDeclaredConstructor().newInstance();
}
throw new IllegalStateException("Not a global provider: " + initializerClazz);
} catch (InstantiationException | IllegalAccessException | ClassNotFoundException | IllegalArgumentException
| InvocationTargetException | NoSuchMethodException | SecurityException e) {
throw new IllegalStateException("Unable to create global provider: " + initializerClassName, e);
}View on GitHub (pinned to e1c734241f)
Solutions
- Verify the configured class implements io.quarkus.qute.Resolver and has a public no-arg constructor.
- Fix the quarkus.qute.resolver.<n>.classes property value to the fully-qualified resolver class.
- Remove the property if a custom resolver is not actually needed.
- Check the Quarkus migration guide if the class changed its interface after an upgrade.
Example fix
// before quarkus.qute.resolver.my-resolver.classes=com.example.MyValueResolver // after quarkus.qute.resolver.my-resolver.classes=com.example.MyResolver // implements io.quarkus.qute.Resolver
Defensive patterns
Strategy: validation
Validate before calling
Class<?> c = Class.forName("com.example.MyResolver");
if (!io.quarkus.qute.Resolver.class.isAssignableFrom(c)) throw new IllegalArgumentException("Not a Resolver"); Type guard
boolean isResolver(Class<?> c) { return io.quarkus.qute.Resolver.class.isAssignableFrom(c); } Try / catch
try { app.start(); } catch (IllegalStateException e) { if (e.getMessage().startsWith("Not a resolver")) { /* fix quarkus.qute.resolver config */ } else throw e; } Prevention
- Double-check FQCNs in quarkus.qute.resolver.* config
- Keep resolver classes in a stable package
- Review Quarkus migration guides when upgrading
When it happens
Trigger: Setting a quarkus.qute.resolver.*.classes property to a class that exists on the classpath but does not implement io.quarkus.qute.Resolver (e.g. a ValueResolver or SectionHelper was configured by mistake).
Common situations: Copy-pasting config between resolver/global-provider properties; configuring a class from an internal or wrong package; a library class that stopped implementing Resolver after a Quarkus version upgrade.
Related errors
- Unable to create resolver:
- Not a global provider:
- Unable to create global provider:
- Unable to create instance of Logging Filter ''
- The <clazz.getSimpleName()> class [<instanceClass>] could no
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/f2d9d6893e152c6c.
Report an issue: GitHub.