Dear Team, I am getting the following error while using flatMap. Caused by: org.apache.flink.client.program.ProgramInvocationException: The main method caused an error: The return type of function 'defineWorkflow(OtelTransformerJob.java:75)' could not be determined automatically, due to type erasure. You can give type information hints by using the returns(...) method on the result of the transformation call, or by letting your function implement the 'ResultTypeQueryable' interface.
On further investigation I found that flatMap should end with .returns(Types.STRING) when the return type is a STRING. My question is if my return type is a custom DTO named mypckg.MyCustomDTO then how do I pass parameters to returns method. Thanks, Tauseef.