Hi Marton. 

I think this is more a class loader issue. My custom class implements 
Serializable and so do all contained members classes. 

Greets. Rico. 



> Am 18.08.2015 um 11:45 schrieb Márton Balassi <balassi.mar...@gmail.com>:
> 
> Hey Rico,
> 
> Currently the Checkpointed interface has the limitation the return type of 
> the snapshotstate method (the generic paramter of Checkpointed) has to be 
> java Serializable. I suspect that is the problem here. This is a limitation 
> that we plan to lift soon.
> 
> Marton
> 
>> On Tue, Aug 18, 2015 at 11:32 AM, Rico Bergmann <i...@ricobergmann.de> wrote:
>> Hi!
>> Is it possible to use your own class?
>> I'm using the file state handler at the Jobmanager and implemented the 
>> Checkpointed interface. 
>> 
>> I tried this and got an exception:
>> 
>> Error: java.lang.RuntimeException: Failed to deserialize state handle and 
>> setup initial operator state.
>> at org.apache.flink.runtime.taskmanager.Task.run(Task.java:544)
>> at java.lang.Thread.run(Thread.java:745)
>> Caused by: java.lang.ClassNotFoundException: 
>> com.ottogroup.bi.searchlab.searchsessionizer.OperatorState
>>> at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
>>> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
>>> at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
>>> at java.lang.Class.forName0(Native Method)
>>> at java.lang.Class.forName(Class.java:348)
>>> at java.io.ObjectInputStream.resolveClass(ObjectInputStream.java:626)
>>> at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1613)
>>> at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1518)
>>> at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1774)
>>> at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1351)
>>> at java.io.ObjectInputStream.readObject(ObjectInputStream.java:371)
>>> at 
>>> org.apache.flink.runtime.state.ByteStreamStateHandle.getState(ByteStreamStateHandle.java:63)
>>> at 
>>> org.apache.flink.runtime.state.ByteStreamStateHandle.getState(ByteStreamStateHandle.java:33)
>>> at 
>>> org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.restoreInitialState(AbstractUdfStreamOperator.java:83)
>>> at 
>>> org.apache.flink.streaming.runtime.tasks.StreamTask.setInitialState(StreamTask.java:276)
>>> at 
>>> org.apache.flink.runtime.state.StateUtils.setOperatorState(StateUtils.java:51)
>>> at org.apache.flink.runtime.taskmanager.Task.run(Task.java:541)
> 

Reply via email to