Aliaksandr Valialkin
a45cbc101f
all: cleanup: remove // +build ...
lines, since they are no longer needed after Go1.17, and the minimum supported Go version for VictoriaMetrics source code is Go1.20
2023-11-13 19:15:42 +01:00
Aliaksandr Valialkin
dcf5b42670
lib/encoding/zstd: switch back from atomic.Pointer to atomic.Value for map[...]...
...
The map[...]... is already a pointer type, so atomic.Pointer[map[...]...] results in double pointer.
This is a follow-up for 140e7b6b74
2023-07-20 21:54:51 -07:00
Aliaksandr Valialkin
992c300ce9
all: replace atomic.Value with atomic.Pointer[T]
...
This eliminates the need in .(*T) casting for results obtained from Load()
Leave atomic.Value for map, since atomic.Pointer[map[...]...] makes double pointer to map,
because map is already a pointer type.
2023-07-19 17:48:26 -07:00
Aliaksandr Valialkin
dfb1d1ead1
lib/encoding: make deterministic tests which rely on math/rand
...
Fixes https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3683
2023-01-23 18:43:49 -08:00
Aliaksandr Valialkin
5d255846ac
all: add go:build
lines for Go1.17
...
See https://tip.golang.org/doc/go1.17#gofmt for more details
2021-07-26 15:50:46 +03:00
Aliaksandr Valialkin
44f886cc9c
lib/encoding/zstd: typo fix
2019-12-23 18:37:20 +02:00
Aliaksandr Valialkin
108a60d69e
lib/encoding/zstd: call zstd.Decoder.Close instead of zstd.Decoder.Reset in order to free up occupied goroutines
...
This should fix goroutine leak for https://github.com/klauspost/compress/issues/195
2019-12-23 18:32:28 +02:00
Aliaksandr Valialkin
335bd0ac0a
lib/encoding/zstd: prevent from possible encoder leak when concurrent goroutines create encoders for the same compressionLevel
...
Thanks to @klauspost for the pointer to this issue. See https://github.com/klauspost/compress/issues/195 for details.
2019-12-23 18:06:02 +02:00
Aliaksandr Valialkin
f2e8d54fb0
lib/encoding/zstd: go fmt
2019-07-25 01:37:57 +03:00
Aliaksandr Valialkin
97b5dc7122
lib/encoding/zstd: disable CRC checks in pure Go
build
...
This should give slightly better compression and decompressions performance.
Additionally this shaves off 4 bytes per each compressed block.
2019-07-24 19:17:32 +03:00
Aliaksandr Valialkin
54f035d4ce
all: small updates after PR #114
2019-07-24 17:43:43 +03:00
Roman Khavronenko
fcf09aaa3c
all: add Pure Go build (pull request #114 )
...
Updates #94
2019-07-24 17:43:32 +03:00