Hi Adrienne, I think you should be able to reinterpretAsKeyedStream by passing in a DataStreamSource based on the ITCase example [1]. Can you share the full code/error logs or the IAE?
-- Rong [1] https://github.com/apache/flink/blob/release-1.7.2/flink-streaming-java/src/test/java/org/apache/flink/streaming/api/datastream/ReinterpretDataStreamAsKeyedStreamITCase.java#L98 On Fri, Mar 29, 2019 at 6:09 AM Adrienne Kole <adrienneko...@gmail.com> wrote: > Dear community, > > I have a use-case where sources are keyed. > For example, there is a source function with parallelism 10, and each > instance has its own key. > I used reinterpretAsKeyedStream to convert source DataStream to > KeyedStream, however, I get an IllegalArgument exception. > Is reinterpretAsKeyedStream can be used with source operators as well, or > should the operator to be used be already partitioned (by keyby(..)) ? > > Thanks, > Adrienne >