aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go9
1 files changed, 8 insertions, 1 deletions
diff --git a/main.go b/main.go
index 91b96e3..2399ceb 100644
--- a/main.go
+++ b/main.go
@@ -41,9 +41,16 @@ func (t *TransactionSummary[IN, OUT]) Apply(ctx context.Context, key string, win
41func main() { 41func main() {
42 // init 42 // init
43 ctx := context.Background() 43 ctx := context.Background()
44 // memory backend
45 // backend := state.NewMemoryStateBackend(1)
46 // pebble backend
47 backend, err := state.NewPebbleStateBackend("./data_pebble", 1)
44 48
45 backend := state.NewMemoryStateBackend(1) 49 if err != nil {
50 panic(err)
51 }
46 52
53 defer backend.Close()
47 ctx = core.InjectStateBackend(ctx, backend) 54 ctx = core.InjectStateBackend(ctx, backend)
48 55
49 txList := []Transaction{ 56 txList := []Transaction{