Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BufferedProtoReader ¶
type BufferedProtoReader struct {
// contains filtered or unexported fields
}
BufferedProtoReader reads the chunks written by BufferedProtoWriter. Callers should call ReadProto until it returns io.EOF, at which point the stream has been exhausted. N.B. This *DOES NOT* guarantee that a caller has read all data for a streamID, because it may still be written to from another goroutine.
func NewBufferedProtoReader ¶
func NewBufferedProtoReader(bs interfaces.Blobstore, streamID string) *BufferedProtoReader
type BufferedProtoWriter ¶
type BufferedProtoWriter struct {
// contains filtered or unexported fields
}
BufferedProtoWriter chunks together and writes protos to blobstore after a chunk exceeds maxBufferSizeBytes size. The caller is responsible for calling Flush to ensure all data is written.
func NewBufferedProtoWriter ¶
func NewBufferedProtoWriter(bs interfaces.Blobstore, streamID string, bufferSizeBytes int) *BufferedProtoWriter
func (*BufferedProtoWriter) TimeSinceLastWrite ¶
func (w *BufferedProtoWriter) TimeSinceLastWrite() time.Duration
func (*BufferedProtoWriter) WriteProtoToStream ¶
Click to show internal directories.
Click to hide internal directories.