{"record":{"id":"1e3004fe90572754","repo":"quarkusio/quarkus","slug":"custom-jdbc-delegate-implementation-with-name-s","errorCode":null,"errorMessage":"Custom JDBC delegate implementation with name '%s' needs to be a subclass of one of the existing Quarkus delegates such as io.quarkus.quartz.runtime.jdbc.QuarkusPostgreSQLDelegate.","messagePattern":"Custom JDBC delegate implementation with name '(.+?)' needs to be a subclass of one of the existing Quarkus delegates such as io\\.quarkus\\.quartz\\.runtime\\.jdbc\\.QuarkusPostgreSQLDelegate\\.","errorType":"exception","errorClass":"ConfigurationException","httpStatus":null,"severity":"error","filePath":"extensions/quartz/deployment/src/main/java/io/quarkus/quartz/deployment/QuartzProcessor.java","lineNumber":167,"sourceCode":"                        driverDelegate.get());\n                throw new ConfigurationException(message);\n            } else {\n                // any custom implementation needs to be a subclass of known Quarkus delegate\n                boolean implementsKnownDelegate = false;\n                for (DotName knownImplementation : Set.of(DELEGATE_MSSQL, DELEGATE_POSTGRESQL, DELEGATE_DB2V8, DELEGATE_STDJDBC,\n                        DELEGATE_HSQLDB)) {\n                    for (ClassInfo classInfo : indexView.getAllKnownSubclasses(knownImplementation)) {\n                        if (classInfo.name().equals(customDelegate.name())) {\n                            implementsKnownDelegate = true;\n                            break;\n                        }\n                    }\n                }\n                if (!implementsKnownDelegate) {\n                    String message = String.format(\n                            \"Custom JDBC delegate implementation with name '%s' needs to be a subclass of one of the existing Quarkus delegates such as io.quarkus.quartz.runtime.jdbc.QuarkusPostgreSQLDelegate.\",\n                            driverDelegate.get());\n                    throw new ConfigurationException(message);\n                }\n            }\n            // A custom delegate implementation, we don't need to check datasources\n            return new QuartzJDBCDriverDialectBuildItem(driverDelegate, null);\n        } else {\n            if (config.deferDatasourceCheck()) {\n                // if defer is set to true and there is a DS name, throw an exception\n                if (config.dataSourceName().isPresent()) {\n                    String message = String.format(\n                            \"Quartz datasource resolution can be either deferred to runtime or specified at build time but not both. Related properties are quarkus.quartz.defer-datasource-check=%s and quarkus.quartz.datasource=%s\",\n                            config.deferDatasourceCheck(), config.dataSourceName());\n                    throw new ConfigurationException(message);\n                }\n                // Defer driver resolution to runtime\n                List<JDBCDataSource> dataSources = new ArrayList<>();\n                for (JdbcDataSourceBuildItem jdbcDataSourceBuildItem : jdbcDataSourceBuildItems) {\n                    dataSources.add(new JDBCDataSource(jdbcDataSourceBuildItem.getName(), jdbcDataSourceBuildItem.isDefault(),\n                            jdbcDataSourceBuildItem.getDbKind()));","sourceCodeStart":149,"sourceCodeEnd":185,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/quartz/deployment/src/main/java/io/quarkus/quartz/deployment/QuartzProcessor.java#L149-L185","documentation":"A custom driver-delegate class was found in the Jandex index, but it is not a subclass of any of Quarkus's known Quartz JDBC delegates (QuarkusMSSQLDelegate, QuarkusPostgreSQLDelegate, QuarkusDBv8Delegate, QuarkusStdJDBCDelegate, QuarkusHSQLDBDelegate). Quarkus requires the extension point to extend one of these known implementations so it can validate the delegate hierarchy and wire it correctly at runtime.","triggerScenarios":"Setting quarkus.quartz.driver-delegate to a class that extends plain org.quartz.impl.jdbcjobstore.StdJDBCDelegate instead of a Quarkus wrapper, or to any unrelated indexed class, while quarkus.quartz.store-type is a DB store.","commonSituations":"Migrating a plain Quartz/SE setup where the custom delegate extended the Quartz StdJDBCDelegate directly; writing a delegate from scratch instead of extending the Quarkus wrapper; refactoring that changed the parent class away from a Quarkus delegate.","solutions":["Make the custom delegate extend io.quarkus.quartz.runtime.jdbc.QuarkusStdJDBCDelegate, QuarkusPostgreSQLDelegate, QuarkusMSSQLDelegate, QuarkusDBv8Delegate, or QuarkusHSQLDBDelegate (matching your database).","If extending the plain Quartz StdJDBCDelegate, switch the superclass to io.quarkus.quartz.runtime.jdbc.QuarkusStdJDBCDelegate and keep custom logic in overridden methods.","If no customization is needed, remove quarkus.quartz.driver-delegate and let Quarkus auto-select the delegate from the datasource db-kind."],"exampleFix":"// before\npublic class MyDelegate extends StdJDBCDelegate { /* ... */ }\n\n// after\nimport io.quarkus.quartz.runtime.jdbc.QuarkusStdJDBCDelegate;\npublic class MyDelegate extends QuarkusStdJDBCDelegate { /* ... */ }","handlingStrategy":"validation","validationCode":"Class<?> c = Class.forName(\"com.example.MyDelegate\", false,\n    Thread.currentThread().getContextClassLoader());\nboolean ok = io.quarkus.quartz.runtime.jdbc.QuarkusStdJDBCDelegate.class.isAssignableFrom(c)\n    || io.quarkus.quartz.runtime.jdbc.QuarkusPostgreSQLDelegate.class.isAssignableFrom(c);\nif (!ok) throw new IllegalStateException(\"Delegate must extend a Quarkus Quartz JDBC delegate\");","typeGuard":"static boolean isQuarkusDelegate(Class<?> c) {\n    return io.quarkus.quartz.runtime.jdbc.QuarkusStdJDBCDelegate.class.isAssignableFrom(c);\n}","tryCatchPattern":null,"preventionTips":["Always extend one of the io.quarkus.quartz.runtime.jdbc.Quarkus*Delegate classes, never plain org.quartz StdJDBCDelegate.","Add a unit test asserting your delegate passes isQuarkusDelegate().","Document in the delegate's Javadoc which Quarkus delegate it extends."],"tags":["quarkus","quartz","jdbc-store","delegate","build-time"],"backgroundTag":"unsupported-spi-extension-point","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-12T22:17:10.623Z"}