diff --git a/internal/bft/controller.go b/internal/bft/controller.go index df9b73bb..bf22a411 100644 --- a/internal/bft/controller.go +++ b/internal/bft/controller.go @@ -254,7 +254,7 @@ func (c *Controller) HandleRequest(sender uint64, req []byte) { c.addRequest(reqInfo, req) } -// SubmitRequest Submits a request to go through consensus. +// SubmitRequest submits a request to go through consensus. func (c *Controller) SubmitRequest(request []byte) error { info := c.RequestInspector.RequestID(request) return c.addRequest(info, request) diff --git a/internal/bft/requestpool.go b/internal/bft/requestpool.go index c9425792..7f98d47a 100644 --- a/internal/bft/requestpool.go +++ b/internal/bft/requestpool.go @@ -23,7 +23,7 @@ const ( defaultRequestTimeout = 10 * time.Second // for unit tests only defaultMaxBytes = 100 * 1024 // default max request size would be of size 100Kb defaultSizeOfDelElements = 1000 // default size slice of delete elements - defaultEraseTimeout = 5 * time.Second // for cicle erase silice of delete elements + defaultEraseTimeout = 5 * time.Second // for cycle erase silice of delete elements ) var ( @@ -46,9 +46,9 @@ type RequestTimeoutHandler interface { OnAutoRemoveTimeout(requestInfo types.RequestInfo) } -// Pool implements requests pool, maintains pool of given size provided during -// construction. In case there are more incoming request than given size it will -// block during submit until there will be place to submit new ones. +// Pool implements a requests pool, maintaining a pool of a given size provided during +// construction. If there are more incoming requests than the given size, it will +// block during submission until there is space to submit new ones. type Pool struct { logger api.Logger metrics *api.MetricsRequestPool diff --git a/internal/bft/viewchanger.go b/internal/bft/viewchanger.go index 78209f8b..9a98a8b2 100644 --- a/internal/bft/viewchanger.go +++ b/internal/bft/viewchanger.go @@ -48,7 +48,7 @@ type change struct { stopView bool } -// ViewChanger is responsible for running the view change protocol +// ViewChanger is responsible for running the view change protocol. type ViewChanger struct { // Configuration SelfID uint64