Skip to content

Commit

Permalink
Merge pull request #125 from traP-jp/polling-properly
Browse files Browse the repository at this point in the history
messageProcesserの並列処理実装がミスっていたのを修正
  • Loading branch information
oribe1115 authored Dec 15, 2023
2 parents bc6cfe1 + 3294c3a commit 1224cd0
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions server/traqmessage/collect.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,11 @@ type messageProcesser struct {

// go routineの中で呼ぶ
func (m *messageProcesser) run() {
select {
case messages := <-m.queue:
m.process(*messages)
for {
select {
case messages := <-m.queue:
m.process(*messages)
}
}
}

Expand Down

0 comments on commit 1224cd0

Please sign in to comment.