public void setValue(RecordKey key, RecordUpdate update)
{
// build a byte[] for the updates using the basic block encoder
MemoryStream writer = new MemoryStream();
// TODO: this seems like a really inefficient way to write out a key
ISegmentBlockEncoder encoder = new SegmentBlockBasicEncoder();
encoder.setStream(writer);
encoder.add(key, update);
encoder.flush();
writer.Flush();
this.addCommand((byte)LogCommands.UPDATE, writer.ToArray());
// Writes are actually applied to the workingSegment when the LgoWriter pushes them to the ILogReceiver.
// This assures, for example, that DISK_ATOMIC writes to not apply to the segments until the writegroup is flushed.
}