public static class GenericWriteAheadSink.ExactlyOnceState extends Object implements StateHandle<Serializable>
Modifier and Type | Field and Description |
---|---|
protected TreeMap<Long,Tuple2<Long,StateHandle<DataInputView>>> |
pendingHandles |
Constructor and Description |
---|
ExactlyOnceState() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
discardState()
Discards the state referred to by this handle, to free up resources in
the persistent storage.
|
TreeMap<Long,Tuple2<Long,StateHandle<DataInputView>>> |
getState(ClassLoader userCodeClassLoader)
This retrieves and return the state represented by the handle.
|
long |
getStateSize()
Returns the size of the state in bytes.
|
String |
toString() |
protected TreeMap<Long,Tuple2<Long,StateHandle<DataInputView>>> pendingHandles
public TreeMap<Long,Tuple2<Long,StateHandle<DataInputView>>> getState(ClassLoader userCodeClassLoader) throws Exception
StateHandle
getState
in interface StateHandle<Serializable>
userCodeClassLoader
- Class loader for deserializing user code specific classesException
- Thrown, if the state cannot be fetched.public void discardState() throws Exception
StateObject
discardState
in interface StateObject
Exception
public long getStateSize() throws Exception
StateObject
If the the size is not known, return 0
.
getStateSize
in interface StateObject
Exception
- If the operation fails during size retrieval.public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.