Change config format to yaml; add replicators
This commit is contained in:
8
db.go
8
db.go
@@ -1,16 +1,14 @@
|
||||
package litestream
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"database/sql"
|
||||
"fmt"
|
||||
"io"
|
||||
"log"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -34,6 +32,10 @@ type DB struct {
|
||||
cancel func()
|
||||
wg sync.WaitGroup
|
||||
|
||||
// List of replicators for the database.
|
||||
// Must be set before calling Open().
|
||||
Replicators []Replicator
|
||||
|
||||
// Frequency at which to perform db sync.
|
||||
MonitorInterval time.Duration
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user