internal/lsp: fix lockup for packages with many files

We should not be sending messages from within the telemetry worker. This does it in a new go routine now.

Change-Id: I55e3b6df04699b8e45bc37b99997463f45ee114e
Reviewed-on: https://go-review.googlesource.com/c/tools/+/186958
Run-TryBot: Ian Cottrell <iancottrell@google.com>
Reviewed-by: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Ian Cottrell 2019-07-19 16:16:41 -04:00 committed by Ian Cottrell
parent e377ae9d63
commit 8bb11ff117

View File

@ -35,6 +35,6 @@ func logger(ctx context.Context, at time.Time, tags tag.List) bool {
if entry.Error != nil {
msg.Type = Error
}
client.LogMessage(xcontext.Detach(ctx), msg)
go client.LogMessage(xcontext.Detach(ctx), msg)
return true
}