Skip to content

Conversation

@aloknerurkar
Copy link
Collaborator

@aloknerurkar aloknerurkar commented Jul 29, 2024

Describe your changes

Add proper health check for mev-commit and oracle.

Issue ticket number and link

#277

Checklist before requesting a review

  • I have added tests that prove my fix is effective or that my feature works
  • I have made corresponding changes to the documentation
  • I have tested this code by deploying the infrastructure and ensuring that commitments are being settled

@aloknerurkar aloknerurkar requested review from Mikelle and mrekucci July 29, 2024 09:51
Copy link
Contributor

@mrekucci mrekucci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The health check should also be used across infra Nomad scripts.


srv := apiserver.New(opts.Version, opts.Logger.With("component", "apiserver"))
peerType := p2p.FromString(opts.PeerType)
healthChecker := health.New()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: this can be defined closer to it's first usage on the line 547.

"google.golang.org/grpc/connectivity"
)

type HealthCheck interface {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HealthCheck -> HealthChecker

})
}

func New() Health {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This constructor is not necessary, I'd suggest to export the health struct below and use new(Health) instead.

@aloknerurkar aloknerurkar merged commit be0e7d9 into main Jul 30, 2024
@aloknerurkar aloknerurkar deleted the health branch July 30, 2024 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants