Skip to content

Commit

Permalink
Merge pull request hashicorp#120 from hashicorp/f-concurrency
Browse files Browse the repository at this point in the history
langserver: Make requests sequential
  • Loading branch information
radeksimko authored May 27, 2020
2 parents 2ad17cd + 1bc4381 commit 1c47e42
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions langserver/langserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ type langServer struct {
func NewLangServer(srvCtx context.Context, sf session.SessionFactory) *langServer {
opts := &jrpc2.ServerOptions{
AllowPush: true,

// Disable concurrency to avoid race conditions
// between requests concerning the same document
Concurrency: 1,
}

return &langServer{
Expand Down

0 comments on commit 1c47e42

Please sign in to comment.