This is more a code refactoring question and Im seeking suggestion on how best to improve code reusability.
I have jobs that do similar things. When I say “similar” I mean: all jobs stream from Kafka (of course different topics), join on stream of cdc (different mysql tables) creating KeyedCoProcessFunction
stream and finally sink to influx.
The structure of these jobs is very similar. Only thing that changes is topic name, sql table name, different POJO types (which are a lot), etc.
I made things generic to reduce bloat. But, Flink cannot determine types at runtime and jobs fail.
So the question is: what are Flink developers doing to reuse code and have less copy/paste code?