Re: Java type erasure and object reuse

2015-09-18 Thread Stephan Ewen
Good problem... We were thinking for a while to make the input and output type serializers available from the RuntimeContext. That way you could call "T copy = serializer.copy(inValue)". The "copy()" method on the copyable value is actually a good addition nonetheless! On Thu, Sep 17, 2015 at

Java type erasure and object reuse

2015-09-17 Thread Greg Hogan
What is best practice for handling Java type erasure in user defined functions? Is there a means by which the TypeInformation can be accessed from a RichFunction? My temporary solution was to add a "T copy()" method to the CopyableValue interface. A common use case is a GroupReduceFunction that