Skip to content

Commit

Permalink
Merge pull request #528 from Roasbeef/never-gonna-give-up-universe-push
Browse files Browse the repository at this point in the history
universe: update pushProofToFederation to make sure all servers are tried
  • Loading branch information
Roasbeef authored Sep 25, 2023
2 parents 603078b + 6444939 commit e81e803
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions universe/auto_syncer.go
Original file line number Diff line number Diff line change
Expand Up @@ -257,14 +257,20 @@ func (f *FederationEnvoy) pushProofToFederation(uniID Identifier, key BaseKey,
pushNewProof := func(ctx context.Context, addr ServerAddr) error {
remoteUniverseServer, err := f.cfg.NewRemoteRegistrar(addr)
if err != nil {
return fmt.Errorf("unable to connect to remote "+
"server(%v): %v", addr.HostStr(), err)
log.Warnf("cannot push proof unable to connect "+
"to remote server(%v): %v", addr.HostStr(),
err)
return nil
}

_, err = remoteUniverseServer.RegisterIssuance(
ctx, uniID, key, leaf,
)
return err
if err != nil {
log.Warnf("cannot push proof to remote "+
"server(%v): %v", addr.HostStr(), err)
}
return nil
}

// To conclude, we'll attempt to push the new proof to all the universe
Expand Down

0 comments on commit e81e803

Please sign in to comment.