+7
-64
cmd/backfiller/backend.go
+7
-64
cmd/backfiller/backend.go
······-func (b *Backend) RepoCommitHandler(ctx context.Context, evt *comatproto.SyncSubscribeRepos_Commit) error {-if err := b.state.Model(cursorRecord{}).Where("id = 1 and val < ?", v).Update("val", v).Error; err != nil {
-168
cmd/backfiller/backfiller.go
-168
cmd/backfiller/backfiller.go
···-func handleCreate(ctx context.Context, repo, rev, path string, rec *[]byte, cid *cid.Cid) error {-func handleUpdate(ctx context.Context, repo, rev, path string, rec *[]byte, cid *cid.Cid) error {-ctx, stop := signal.NotifyContext(context.Background(), os.Interrupt, syscall.SIGINT, syscall.SIGTERM)-bf := backfill.NewBackfiller("backfills", store, handleCreate, handleUpdate, handleDelete, opts)
+51
cmd/backfiller/cursors.go
+51
cmd/backfiller/cursors.go
···+if err := b.state.Model(cursorRecord{}).Where("key = 'firehose'").Update("val", b.firehoseSeq).Error; err != nil {+if err := b.state.Model(cursorRecord{}).Where("key = 'repos'").Update("val", b.reposSeq).Error; err != nil {
+40
cmd/backfiller/handlers.go
+40
cmd/backfiller/handlers.go
···+func (b *Backend) RepoCommitHandler(ctx context.Context, evt *comatproto.SyncSubscribeRepos_Commit) error {+func handleCreate(ctx context.Context, repo, rev, path string, rec *[]byte, cid *cid.Cid) error {+func handleUpdate(ctx context.Context, repo, rev, path string, rec *[]byte, cid *cid.Cid) error {
+117
cmd/backfiller/main.go
+117
cmd/backfiller/main.go
···+ctx, stop := signal.NotifyContext(context.Background(), os.Interrupt, syscall.SIGINT, syscall.SIGTERM)
+76
cmd/backfiller/pump.go
+76
cmd/backfiller/pump.go
···