# Schema Registry Could Not Be Started

**URL:** https://forum.confluent.io/t/schema-registry-could-not-be-started/9069
**Category:** Schema Registry
**Created:** [13 November 2023 16:44 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069 "2023-11-13T16:44:42Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![f2498985](https://avatars.discourse-cdn.com/v4/letter/f/47e85d/32.png) [@f2498985](https://forum.confluent.io/u/f2498985)
#### Post date: [13 November 2023 16:44 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/1 "2023-11-13T16:44:42Z")

</div>

Hello.

I have build Schema Registry from github sources, trying to start and got

```auto
[2023-11-13 19:39:49,099] INFO Adding listener with HTTP/2: NamedURI{uri=http://0.0.0.0:8081, name='null'} (io.confluent.rest.ApplicationServer:307)
[2023-11-13 19:39:49,314] ERROR Server died unexpectedly: (io.confluent.kafka.schemaregistry.rest.SchemaRegistryMain:55)
org.apache.kafka.common.KafkaException: Class io.confluent.dekregistry.DekRegistryResourceExtension cannot be found
	at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:392)
	at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstances(AbstractConfig.java:483)
	at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstances(AbstractConfig.java:461)
	at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstances(AbstractConfig.java:447)
	at io.confluent.kafka.schemaregistry.storage.KafkaSchemaRegistry.<init>(KafkaSchemaRegistry.java:174)
	at io.confluent.kafka.schemaregistry.rest.SchemaRegistryRestApplication.initSchemaRegistry(SchemaRegistryRestApplication.java:73)
	at io.confluent.kafka.schemaregistry.rest.SchemaRegistryRestApplication.configureBaseApplication(SchemaRegistryRestApplication.java:103)
	at io.confluent.rest.Application.configureHandler(Application.java:324)
	at io.confluent.rest.ApplicationServer.doStart(ApplicationServer.java:212)
	at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
	at io.confluent.kafka.schemaregistry.rest.SchemaRegistryMain.main(SchemaRegistryMain.java:44)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at org.codehaus.mojo.exec.ExecJavaMojo$1.run(ExecJavaMojo.java:297)
	at java.base/java.lang.Thread.run(Thread.java:840)
Caused by: java.lang.ClassNotFoundException: io.confluent.dekregistry.DekRegistryResourceExtension
	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:445)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:592)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
	at java.base/java.lang.Class.forName0(Native Method)
	at java.base/java.lang.Class.forName(Class.java:467)
	at org.apache.kafka.common.utils.Utils.loadClass(Utils.java:425)
	at org.apache.kafka.common.utils.Utils.newInstance(Utils.java:414)
	at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:390)

```

Can someone help with solution?

As I see, the problem is with [Install and Configure the Schema Registry Security Plugin | Confluent Documentation](https://docs.confluent.io/platform/current/confluent-security-plugins/schema-registry/install.html#resource-extension-class) ?

There is a difference between docs and code lines

```auto
# resource.extension.class=io.confluent.dekregistry.DekRegistryResourceExtension
resource.extension.class=io.confluent.kafka.schemaregistry.security.SchemaRegistrySecurityResourceExtension

```

Another attempt. I see the file

```auto
dek-registry/src/main/java/io/confluent/dekregistry/DekRegistryResourceExtension.java

```

trying to

```auto
cd dek-registry
mvn compile

```

gives an error

```auto
[ERROR] Could not find resource 'findbugs/findbugs-exclude.xml'. -> [Help 1]

```

What can be a solution?

---

<div class="post-metadata">

### Author: ![dtroiano](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/dtroiano/32/1961_2.png) [@dtroiano](https://forum.confluent.io/u/dtroiano)
#### Post date: [14 November 2023 14:40 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/2 "2023-11-14T14:40:47Z")

</div>

What branch are you trying to build and how are you building? I ran `mvn package` followed by `./bin/schema-registry-start config/schema-registry.properties` and Schema Registry started up without error. I built the `7.5.1-post` branch for speed since the `7.5.1` [`common`](https://github.com/confluentinc/common) and [`rest-utils`](https://github.com/confluentinc/rest-utils) dependencies mentioned [here](https://github.com/confluentinc/schema-registry#development) are publicly available. For a more recent branch you’d need to check out the corresponding branches of those repos and build / install the dependencies.

---

<div class="post-metadata">

### Author: ![dtroiano](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/dtroiano/32/1961_2.png) [@dtroiano](https://forum.confluent.io/u/dtroiano)
#### Post date: [14 November 2023 17:28 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/5 "2023-11-14T17:28:28Z")

</div>

My mistake - I really should have been on `7.5.2-post` since `7.5.2` is the latest Confluent Platform release and therefore the latest published dependency version on `packages.confluent.io` (e.g., see [`rest-utils-parent`](https://packages.confluent.io/maven/io/confluent/rest-utils-parent/7.5.2/), which Schema Registry depends on). Think of `-post` as the latest hotfixed 7.5.2 picture of Schema Registry.

The other later tags are all pre-release, which you could probably also use if you want (or be on the `master` branch of all), but again keep in mind you’d have to locally build and install Common and Rest Utils first.

---

<div class="post-metadata">

### Author: ![dtroiano](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/dtroiano/32/1961_2.png) [@dtroiano](https://forum.confluent.io/u/dtroiano)
#### Post date: [14 November 2023 21:33 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/7 "2023-11-14T21:33:22Z")

</div>

The `post` branch is the post-release branch that might get compatibility fixes (e.g., say `packages.confluent.io` repository URL changed) but is otherwise pretty stable.

The tags are incremental builds.

`master` is the bleeding edge.

I would think that you’d either want to be closer to stable in which case you’d build from the `-post` branch, or on _the_ bleeding edge; i.e., I can’t think of a use case for building from one of the tags. You’d have to have a good / informed reason to be doing that as opposed to `master`.

---

<div class="post-metadata">

### Author: ![OneCricketeer](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/onecricketeer/32/1551_2.png) [@OneCricketeer](https://forum.confluent.io/u/OneCricketeer)
#### Post date: [15 November 2023 06:32 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/9 "2023-11-15T06:32:13Z")

</div>

My suggestion, if you’re not looking to fork or contribute any code, just download Confluent Platform and run only the schema registry script. You can optionally remove extra packages and scripts, then redistribute the package within some internal repository / package manager. This way, there won’t be any JDK compilation differences between your system and Confluent’s build servers.

Docker images would also suffice for running the registry on its own.

---

<div class="post-metadata">

### Author: ![f2498985](https://avatars.discourse-cdn.com/v4/letter/f/47e85d/32.png) [@f2498985](https://forum.confluent.io/u/f2498985)
#### Post date: [15 November 2023 12:17 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/11 "2023-11-15T12:17:01Z")

</div>

When I have tried to build from `7.5.2-post` branch, I got an error

```auto
69.17 FAILURE: Build failed with an exception.
69.17 
69.17 
69.17 Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.
69.17 * What went wrong:
69.17 Execution failed for task ':connect:signMavenJavaPublication'.
69.17 > Cannot perform signing task ':connect:signMavenJavaPublication' because it has no configured signatory
69.17 
69.17 * Try:
69.17 > Run with --stacktrace option to get the stack trace.
69.17 > Run with --info or --debug option to get more log output.
69.17 > Run with --scan to get full insights.
69.17 > Get more help at https://help.gradle.org.
69.17 
69.17 You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
69.17 
69.17 For more on this, please refer to https://docs.gradle.org/8.4/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.
69.17 BUILD FAILED in 1m 8s
69.17 
69.17 80 actionable tasks: 80 executed
------
failed to solve: process "/bin/sh -c /home/engineer/.sdkman/candidates/gradle/current/bin/gradle --no-daemon --exclude-task test jar install releaseTarGz" did not complete successfully: exit code: 1

```

When I am building from `v7.5.3-2.css`, all is fine.

Maybe, I must customize build script to build properly from the `post` branch?

---

<div class="post-metadata">

### Author: ![f2498985](https://avatars.discourse-cdn.com/v4/letter/f/47e85d/32.png) [@f2498985](https://forum.confluent.io/u/f2498985)
#### Post date: [15 November 2023 22:15 UTC](https://forum.confluent.io/t/schema-registry-could-not-be-started/9069/12 "2023-11-15T22:15:13Z")

</div>

Can you, please, suggest, can I use Maven to get latest build of Schema Registry with all necessary dependencies?
