Skip to content

Commit

Permalink
Make sure deadlock detection is turned off.
Browse files Browse the repository at this point in the history
  • Loading branch information
winder committed Aug 16, 2022
1 parent 0f8b33d commit bc2dbbc
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions cmd/algorand-indexer/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import (
"github.com/algorand/indexer/idb"
"github.com/algorand/indexer/idb/dummy"
_ "github.com/algorand/indexer/idb/postgres"
_ "github.com/algorand/indexer/util/disable_deadlock"
"github.com/algorand/indexer/util/metrics"
"github.com/algorand/indexer/version"
)
Expand Down
1 change: 0 additions & 1 deletion processor/blockprocessor/internal/catchupservice.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ func CatchupServiceCatchup(ctx context.Context, logger *log.Logger, catchpoint,

start := time.Now()
cfg := config.AutogenLocal
cfg.DeadlockDetection = 0

node := makeNodeProvider(ctx)
l, err := util.MakeLedger(logger, false, &genesis, dataDir)
Expand Down
8 changes: 8 additions & 0 deletions util/disable_deadlock/disable_deadlock.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package disable_deadlock

import "github.com/algorand/go-deadlock"

func init() {
// disable go-deadlock detection
deadlock.Opts.Disable = true
}

0 comments on commit bc2dbbc

Please sign in to comment.