New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Headless KSQL to support schema inference (Avro) #1530
Comments
This is an important thing for us to fix to enable people to painlessly move from dev through to production. |
+1 from me - this is a biggie for production. |
|
@yunhappy : Please upvote (+1 / thumbs-up) the first message/comment in this thread, this way we can track the number of upvotes more easily. |
This is in direct conflict with issue #2205. The issue with supporting avro field inference in headless mode is that the schema could change over time. So we might start KSQL only to find the schema has changed, with columns added / removed. How should KSQL handle such a change? Currently, in interactive mode, the schema is queried once and then baked into the command topic. We could support something similar for headless. I know @rodesai is looking to store other system metadata in a topic in headless mode. Maybe this could be too. Alternatively, we can look at supporting schema evolution in both headless and interactive. But this is a larger piece of work and probably a more long term goal / feature. As for #2205, I see that as just a quick 'make KSQL fail hard and fast' until we get around to adding true support for this, i.e. fix the fact it currently parses OK, but doesn't actually work. |
+1 |
Closing this issue. If there are future requests similar to this, please reopen or create a new issue. |
Schema inference doesn't work when using headless KSQL. For example, when your input data is in Avro format, you must still enter column names/types manually (when KSQL is run in headless config).
The problem with headless (non-interactive mode) is that the engine parses all the queries in the set up front, and fails if any of the fields are not found in the meta store. The schema inference is done during execution, which happens after parsing. So if a subsequent query refers to an inferred field, it will fail with the parse exception.
Related Issues
We also have other issues because of this dichotomy between the way our interactive and non-interactive modes operate.
run script
versus interactive)The text was updated successfully, but these errors were encountered: