org.apache.hadoop.chukwa.datacollection.writer
Class InMemoryWriter
java.lang.Object
org.apache.hadoop.chukwa.datacollection.writer.InMemoryWriter
- All Implemented Interfaces:
- ChukwaWriter
public class InMemoryWriter
- extends Object
- implements ChukwaWriter
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
InMemoryWriter
public InMemoryWriter()
close
public void close()
- Specified by:
close
in interface ChukwaWriter
init
public void init(org.apache.hadoop.conf.Configuration conf)
throws WriterException
- Specified by:
init
in interface ChukwaWriter
- Throws:
WriterException
add
public void add(Chunk data)
throws WriterException
- Throws:
WriterException
add
public void add(List<Chunk> chunks)
throws WriterException
- Specified by:
add
in interface ChukwaWriter
- Throws:
WriterException
readOutChunk
public Chunk readOutChunk(int bytes,
int ms)
throws IOException
- Try to read bytes, waiting up to ms
- Parameters:
bytes
- amount to try to readms
- time to wait
- Returns:
- a newly read-in chunk
- Throws:
IOException
Copyright © ${year} The Apache Software Foundation