Initial commit: archer, a Go-native MySQL/MariaDB table archiver
Renamed from arcdb: module path, cmd/archer, internal/archererr, docs, build scripts and ARCHER_* environment variables. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
commit
bc4a6b504f
99 files changed
+12752
No files matched your search
@@ -0,0 +1,21 @@
|
||||
// Package sink contains the file and database write targets.
|
||||
package sink
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"archer/internal/row"
|
||||
"archer/internal/shard"
|
||||
)
|
||||
|
||||
// File writes chunks into shard files.
|
||||
type File struct {
|
||||
W *shard.Writer
|
||||
}
|
||||
|
||||
func (f *File) WriteChunk(_ context.Context, c *row.Chunk) error { return f.W.WriteChunk(c) }
|
||||
func (f *File) Flush(context.Context) error { return f.W.Flush() }
|
||||
func (f *File) Close() error { return f.W.Close() }
|
||||
|
||||
// Checkpoint makes buffered shard data durable before a destructive commit.
|
||||
func (f *File) Checkpoint() error { return f.W.Checkpoint() }
|
||||
Reference in new issue
Block a user