Skip to content

Make Snapshots streamable by not requiring a known size up front. #601

Open
@otoolep

Description

@otoolep

https://pkg.go.dev/github.com/hashicorp/raft#SnapshotMeta

I am implementing (not for the first time) my own Snapshot Store in rqlite. I am reading a Snapshot data from an uncompressed source, but would like to compress it on the fly when a Snapshot it the data is read from the io.ReadCloser returned by Snapshot store.Open().

Since the source data is not itself compressed, but compressed bytes will be served by the io.ReadCloser, I do not know the size of the Snapshot data ahead of time. This forces me to compress the data first in a scratch area.

Any ideas for avoiding this?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions