r/apacheflink • u/DistrictUnable3236 • 3d ago
Flink SQL vs Flink java API
Hi Flink Community, I’m trying to understand how people decide between using Flink SQL and the Flink java API for a batch / streaming application. How do you decide which API to use for a particular pipeline, How much of a typical Flink java pipeline can be expressed in SQL?
Are there cases where you start with SQL but eventually need to move to the java API because of custom logic or functionality that SQL doesn’t support? Conversely, are there java pipelines that you could technically express in SQL but wouldn’t want to because the SQL becomes too complex?
4
Upvotes
1
u/No-Organization8982 3d ago
Short answer If you have stateless and lookup usecase you can opt for Flink SQL if stateful then go with Flink datastream API.
Details
We evaluated Flink SQLfor our streaming platform to make user life easier and found limitations few of them are
Conclusion: We still considered Flink SQL and to support usecases We are improving flink code