diff --git a/Dockerfile b/Dockerfile index cf8d7de90..b5da97c11 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,3 +20,6 @@ ENV MICRONAUT_CONFIG_FILES=/app/application.yml USER akhq ENTRYPOINT ["docker-entrypoint.sh"] CMD ["./akhq"] + + + diff --git a/docker/usr/local/bin/docker-entrypoint.sh b/docker/usr/local/bin/docker-entrypoint.sh index 24e3f320d..bcae33a14 100755 --- a/docker/usr/local/bin/docker-entrypoint.sh +++ b/docker/usr/local/bin/docker-entrypoint.sh @@ -11,4 +11,4 @@ fi # https://github.com/docker-library/docs/blob/master/eclipse-temurin/content.md#can-i-add-my-internal-ca-certificates-to-the-truststore # To fix this issue, we invoke the base image ENTRYPOINT script (/__cacert_entrypoint.sh) before the arguments. # Credits to https://superuser.com/a/1460890 -exec /__cacert_entrypoint.sh "$@" +exec /__cacert_entrypoint.sh "$@" \ No newline at end of file diff --git a/src/main/java/org/akhq/repositories/SchemaRegistryRepository.java b/src/main/java/org/akhq/repositories/SchemaRegistryRepository.java index c99b649a6..a5aef3e69 100644 --- a/src/main/java/org/akhq/repositories/SchemaRegistryRepository.java +++ b/src/main/java/org/akhq/repositories/SchemaRegistryRepository.java @@ -1,5 +1,9 @@ package org.akhq.repositories; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + + import com.amazonaws.services.schemaregistry.deserializers.GlueSchemaRegistryKafkaDeserializer; import com.amazonaws.services.schemaregistry.utils.AWSSchemaRegistryConstants; import com.amazonaws.services.schemaregistry.utils.AvroRecordType; @@ -41,6 +45,10 @@ public class SchemaRegistryRepository extends AbstractRepository { public static final int ERROR_NOT_FOUND = 40401; + private static final Logger log = + LoggerFactory.getLogger(SchemaRegistryRepository.class); + + @Inject private KafkaModule kafkaModule; @@ -66,9 +74,12 @@ private List toSchemasLatestVersion(List subjectList, String clu try { return getLatestVersion(clusterId, s); } catch (RestClientException | IOException e) { - throw new RuntimeException(e); + log.warn("Unable to fetch latest version for schema {}" , s , e ); + return null; } }) + .filter(Objects::nonNull) + .collect(Collectors.toList()); }