Thanks for ur suggestions!

On Fri, Feb 5, 2021 at 11:16 PM Timo Walther <twal...@apache.org> wrote:

> Dealing with types is not always easy in Flink. If you have further
> issues, it might make sense to just pass them explicitly. We list all
> types in:
>
> org.apache.flink.api.common.typeinfo.Types
>
> org.apache.flink.api.scala.typeutils.Types
>
> Regards,
> Timo
>
> On 05.02.21 16:04, Xavier wrote:
> > Hi Timo,
> >      Thank you for ur clarification, it is very useful to me, I am also
> > combining the realization of map function, trying to do implicit
> > conversion of case class, so that I can restore state from FS.
> >
> > On Fri, Feb 5, 2021 at 10:38 PM Timo Walther <twal...@apache.org
> > <mailto:twal...@apache.org>> wrote:
> >
> >     Hi Xavier,
> >
> >     the Scala API has special implicits in method such as
> >     `DataStream.map()`
> >     or `DataStream.keyBy()` to support Scala specifics like case classe.
> >     For
> >     Scala one needs to use the macro `createTypeInformation[CaseClass]`
> for
> >     Java we use reflection via `TypeInformation.of()`. But Scala and Java
> >     analysis is completely different. So you cannot use a case class in
> >     Java
> >     API. Scala will fall back to Java though.
> >
> >     I hope this helps.
> >
> >     Regards,
> >     Timo
> >
> >
> >     On 05.02.21 10:54, Xavier wrote:
> >      > Hi Utopia,
> >      >     Have u fixed this problem? I also meet this problem, so I
> >     transferred the
> >      > case class to Java POJO, then this problem was fixed.
> >      >
> >      >
> >      >
> >      > --
> >      > Sent from:
> >     http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
> >     <
> http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/>
> >      >
> >
> >
> >
> > --
> >
> > Best Regards,
> > *Xavier*
>
>

-- 

Best Regards,
*Xavier*

Reply via email to