public class MemCheckpointStreamFactory extends Object implements CheckpointStreamFactory
CheckpointStreamFactory that produces streams that write to in-memory byte arrays.| Modifier and Type | Class and Description |
|---|---|
static class |
MemCheckpointStreamFactory.MemoryCheckpointOutputStream
A
CheckpointStateOutputStream that writes into a byte array. |
CheckpointStreamFactory.CheckpointStateOutputStream| Constructor and Description |
|---|
MemCheckpointStreamFactory(int maxStateSize)
Creates a new in-memory stream factory that accepts states whose serialized forms are
up to the given number of bytes.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the stream factory, releasing all internal resources, but does not delete any
persistent checkpoint data.
|
CheckpointStreamFactory.CheckpointStateOutputStream |
createCheckpointStateOutputStream(long checkpointID,
long timestamp)
Creates an new
CheckpointStreamFactory.CheckpointStateOutputStream. |
String |
toString() |
public MemCheckpointStreamFactory(int maxStateSize)
maxStateSize - The maximal size of the serialized statepublic void close()
throws Exception
CheckpointStreamFactoryclose in interface CheckpointStreamFactoryException - Exceptions can be forwarded and will be logged by the systempublic CheckpointStreamFactory.CheckpointStateOutputStream createCheckpointStateOutputStream(long checkpointID, long timestamp) throws Exception
CheckpointStreamFactoryCheckpointStreamFactory.CheckpointStateOutputStream. When the stream
is closed, it returns a state handle that can retrieve the state back.createCheckpointStateOutputStream in interface CheckpointStreamFactorycheckpointID - The ID of the checkpoint.timestamp - The timestamp of the checkpoint.Exception - Exceptions may occur while creating the stream and should be forwarded.Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.