Skip to content

Commit

Permalink
fix: print root cause in error message
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenpyzhang committed Feb 10, 2020
1 parent 307c0f4 commit b24579a
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import io.confluent.ksql.schema.ksql.inference.TopicSchemaSupplier.SchemaResult;
import io.confluent.ksql.statement.ConfiguredStatement;
import io.confluent.ksql.statement.Injector;
import io.confluent.ksql.util.ErrorMessageUtil;
import io.confluent.ksql.util.IdentifierUtil;
import io.confluent.ksql.util.KsqlException;
import io.confluent.ksql.util.KsqlStatementException;
Expand Down Expand Up @@ -79,7 +80,7 @@ public <T extends Statement> ConfiguredStatement<T> inject(
} catch (final KsqlStatementException e) {
throw e;
} catch (final KsqlException e) {
throw new KsqlStatementException(e.getMessage(), statement.getStatementText(), e.getCause());
throw new KsqlStatementException(ErrorMessageUtil.buildErrorMessage(e), statement.getStatementText(), e.getCause());
}
}

Expand Down

0 comments on commit b24579a

Please sign in to comment.