Skip to content

Commit

Permalink
Fix NPE
Browse files Browse the repository at this point in the history
  • Loading branch information
rayokota committed Aug 3, 2024
1 parent 2b3c3b4 commit 8b3d550
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/io/kcache/kwack/KwackEngine.java
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,7 @@ private void initTable(DuckDBConnection conn, String topic) {
try {
conn.createStatement().execute(ddl);
} catch (SQLException e) {
LOG.warn("Could not execute DDL: {}", e.getMessage());
// ignore, as type may already exist if more than one topic is being processed
}
}

Expand Down Expand Up @@ -801,8 +801,9 @@ public void handleUpdate(Headers headers,
if (valueSerde.usesSchemaRegistry()) {
valueSchemaId = schemaIdFor(value.get());
}
Object originalKey = keyObj._1 != null ? keyObj._1.getOriginalMessage() : null;
valueObj = deserializeValue(
topic, keyObj._1.getOriginalMessage(), value != null ? value.get() : null);
topic, originalKey, value != null ? value.get() : null);

Struct rowInfo = null;
if (rowInfoSize > 0) {
Expand Down

0 comments on commit 8b3d550

Please sign in to comment.