func (s *FileSnapshotSink) Write(b []byte) (int, error) {
	return s.buffered.Write(b)
}
func (s *FileSnapshotSink) Write(b []byte) (int, error) {
	return s.buffered.Write(b)
}
// Write is used to append to the state file. We write to the
// buffered IO object to reduce the amount of context switches.