Skip to content

Commit b9ed339

Browse files
aheliumjnadler
authored andcommitted
Adjust spelling, Address linter warnings for digitalocean#5 (digitalocean#8)
* Adjust spelling, Address linter warnings
1 parent f956e81 commit b9ed339

File tree

10 files changed

+23
-21
lines changed

10 files changed

+23
-21
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ clean:
1919
format:
2020
@go fmt
2121
@go get golang.org/x/tools/cmd/goimports
22-
@goimports -w $$(find . -name '*.go' | grep -v vendor)
22+
@goimports -w $$(find . -name '*.go' | grep -v 'mock_*')
2323

2424
lint: .makecache .makecache/lint
2525

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ require (
2121
github.com/tidwall/gjson v1.2.1 // indirect
2222
github.com/tidwall/match v1.0.1 // indirect
2323
github.com/tidwall/pretty v0.0.0-20180105212114-65a9db5fad51 // indirect
24-
golang.org/x/sys v0.0.0-20191110163157-d32e6e3b99c4 // indirect
24+
golang.org/x/sys v0.0.0-20191113165036-4c7a9d0fe056 // indirect
2525
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
2626
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
2727
gopkg.in/yaml.v2 v2.2.5

go.sum

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,15 +175,16 @@ golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5h
175175
golang.org/x/sys v0.0.0-20190422165155-953cdadca894 h1:Cz4ceDQGXuKRnVBDTS23GTn/pU5OE2C0WrNTOYK1Uuc=
176176
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
177177
golang.org/x/sys v0.0.0-20190801041406-cbf593c0f2f3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
178-
golang.org/x/sys v0.0.0-20191110163157-d32e6e3b99c4 h1:Hynbrlo6LbYI3H1IqXpkVDOcX/3HiPdhVEuyj5a59RM=
179-
golang.org/x/sys v0.0.0-20191110163157-d32e6e3b99c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
178+
golang.org/x/sys v0.0.0-20191113165036-4c7a9d0fe056 h1:dHtDnRWQtSx0Hjq9kvKFpBh9uPPKfQN70NZZmvssGwk=
179+
golang.org/x/sys v0.0.0-20191113165036-4c7a9d0fe056/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
180180
golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg=
181181
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
182182
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4 h1:SvFZT6jyqRaOeXpc5h/JSfZenJ2O330aBsf7JfSUXmQ=
183183
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
184184
golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
185185
golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
186186
golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
187+
golang.org/x/tools v0.0.0-20190312170243-e65039ee4138 h1:H3uGjxCR/6Ds0Mjgyp7LMK81+LvmbvWWEnJhzk1Pi9E=
187188
golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
188189
google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk=
189190
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=

helpers.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import (
55
"strconv"
66
)
77

8+
// Nodeconfig holds a Nodes configuration
89
type Nodeconfig map[string]string
910

1011
// IntConfig validates and fetches the int-typed optional config value specified by 'name', using the 'defaultValue' if

internal/testnodetypes.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ func (a *AsyncFilterNode) Receive(msg fbcontext.Message) error {
388388
return errors.New("message not supported")
389389
}
390390

391-
// IndexRequestBuildlerNode is a Node that converts strings to elasticsearch IndexRequests
391+
// IndexRequestBuilderNode is a Node that converts strings to elasticsearch IndexRequests
392392
type IndexRequestBuilderNode struct {
393393
docNum int
394394
fbcontext.ContextAware

leader/leader.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ func (l *Leader) updateLeadership(status leaderelection.Status) {
117117
}
118118

119119
// connectZk establishes a Zookeeper client connection. The underlying client library does not block on creating the initial
120-
// conection, so no error will be returned from zk.Connect if zookeeper is not available.
120+
// connection, so no error will be returned from zk.Connect if zookeeper is not available.
121121
func connectZk(zkHosts string) (*zk.Conn, <-chan zk.Event) {
122122
zks := strings.Split(zkHosts, ",")
123123

message/kafkamessagesender.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ func (s KafkaMessageSender) Ack(msg Message) error {
5353

5454
func (s *KafkaMessageSender) produceMessage(msg Message, ack bool) error {
5555
wireMsg := &wireMessage{
56-
Message: msg,
57-
Updated: time.Now(),
58-
Acknowleged: ack,
56+
Message: msg,
57+
Updated: time.Now(),
58+
Acknowledged: ack,
5959
}
6060

6161
wireMsgBytes, err := json.Marshal(wireMsg)

message/kafkamessagewire.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ import (
66

77
// wireMessage is the structure that we send on the Kafka topic
88
type wireMessage struct {
9-
Message Message `json:"message"`
10-
Updated time.Time `json:"updated"`
11-
Acknowleged bool `json:"ack"`
9+
Message Message `json:"message"`
10+
Updated time.Time `json:"updated"`
11+
Acknowledged bool `json:"ack"`
1212
}
1313

1414
// uniqueKey concatenates messagetype with the key so that we don't risk collisions across message producers

message/kakfamessagereceiver.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ func (r *KafkaMessageReceiver) processMessage(value []byte) {
199199
if !r.initialized {
200200
r.initBuffer[uniqueKey(wireMsg.Message)] = wireMsg
201201
} else {
202-
if !wireMsg.Acknowleged {
202+
if !wireMsg.Acknowledged {
203203
r.deliverMessage(wireMsg.Message)
204204
}
205205
}
@@ -217,7 +217,7 @@ func (r *KafkaMessageReceiver) deliverMessage(msg Message) {
217217
func (r *KafkaMessageReceiver) processInitBuffer() {
218218
log.WithField("buffered_messages", len(r.initBuffer)).Info("kafkamessagereceiver: delivering buffered messages")
219219
for _, wireMsg := range r.initBuffer {
220-
if !wireMsg.Acknowleged {
220+
if !wireMsg.Acknowledged {
221221
msg := wireMsg.Message
222222
log.WithField("message_key", msg.Key).WithField("message_type", msg.MessageType).Infof("kafkamessagereceiver: delivering initial message")
223223
r.deliverMessage(msg)

0 commit comments

Comments
 (0)