diff --git a/domain/ide/workspace/folder.go b/domain/ide/workspace/folder.go index e1ec76cc7..f7e5b5bda 100644 --- a/domain/ide/workspace/folder.go +++ b/domain/ide/workspace/folder.go @@ -24,7 +24,7 @@ import ( "strings" "sync" - "github.com/puzpuzpuz/xsync" + "github.com/puzpuzpuz/xsync/v3" "github.com/rs/zerolog/log" "github.com/snyk/go-application-framework/pkg/configuration" "github.com/snyk/go-application-framework/pkg/local_workflows/json_schemas" @@ -87,7 +87,7 @@ func NewFolder(path string, name string, scanner snyk.Scanner, hoverService hove scanNotifier: scanNotifier, notifier: notifier, } - folder.documentDiagnosticCache = xsync.NewMapOf[[]snyk.Issue]() + folder.documentDiagnosticCache = xsync.NewMapOf[string, []snyk.Issue]() return &folder } diff --git a/domain/ide/workspace/folder_test.go b/domain/ide/workspace/folder_test.go index f678496b3..57560f019 100644 --- a/domain/ide/workspace/folder_test.go +++ b/domain/ide/workspace/folder_test.go @@ -25,7 +25,7 @@ import ( "time" "github.com/golang/mock/gomock" - "github.com/puzpuzpuz/xsync" + "github.com/puzpuzpuz/xsync/v3" "github.com/snyk/go-application-framework/pkg/configuration" localworkflows "github.com/snyk/go-application-framework/pkg/local_workflows" "github.com/snyk/go-application-framework/pkg/local_workflows/json_schemas" diff --git a/go.mod b/go.mod index ec8de92e2..c614bb843 100644 --- a/go.mod +++ b/go.mod @@ -18,6 +18,7 @@ require ( github.com/pingcap/errors v0.11.4 github.com/pkg/errors v0.9.1 github.com/puzpuzpuz/xsync v1.5.2 + github.com/puzpuzpuz/xsync/v3 v3.0.1 github.com/rs/zerolog v1.30.0 github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06 github.com/segmentio/analytics-go v3.1.0+incompatible diff --git a/go.sum b/go.sum index 2566080d4..e197256fc 100644 --- a/go.sum +++ b/go.sum @@ -344,6 +344,8 @@ github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7z github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/puzpuzpuz/xsync v1.5.2 h1:yRAP4wqSOZG+/4pxJ08fPTwrfL0IzE/LKQ/cw509qGY= github.com/puzpuzpuz/xsync v1.5.2/go.mod h1:K98BYhX3k1dQ2M63t1YNVDanbwUPmBCAhNmVrrxfiGg= +github.com/puzpuzpuz/xsync/v3 v3.0.1 h1:yhTYnDJlgIYp/3Bb14b43VfUPrk/QNJ1HrLYEZ8r2AE= +github.com/puzpuzpuz/xsync/v3 v3.0.1/go.mod h1:VjzYrABPabuM4KyBh1Ftq6u8nhwY5tBPKP9jpmh0nnA= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= diff --git a/licenses/github.com/puzpuzpuz/xsync/v3/LICENSE b/licenses/github.com/puzpuzpuz/xsync/v3/LICENSE new file mode 100644 index 000000000..837697194 --- /dev/null +++ b/licenses/github.com/puzpuzpuz/xsync/v3/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2021 Andrey Pechkurov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE.