fix(deps): update module github.com/puzpuzpuz/xsync to v4 #286
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
v1.5.2->v4.1.0Warning
Some dependencies could not be looked up. Check the Dependency Dashboard for more information.
Release Notes
puzpuzpuz/xsync (github.com/puzpuzpuz/xsync)
v4.1.0Compare Source
UMPSCQueue#168LoadAndDeleteandDeletein case of non-existingMapkey #167Mapresize #170UMPSCQueueis meant to serve as a replacement for a channel. However, crucially, it has infinite capacity. This is a very bad idea in many cases as it means that it never exhibits backpressure. In other words, if nothing is consuming elements from the queue, it will eventually consume all available memory and crash the process. However, there are also cases where this is desired behavior as it means the queue will dynamically allocate more memory to store temporary bursts, allowing producers to never block while the consumer catches up.From now on,
Mapspawns additional goroutines to speed up resizing the hash table. This can be disabled when creating aMapwith the newWithSerialResizesetting:Thanks @PapaCharlie and @llxisdsh for the contributions!
v4.0.0Compare Source
MapOf's hasher API is gone. The default and only hash function is now based onmaphash.Comparable.Map'sComputeAPI now supports no-op (cancel) compute operation.Thanks @PapaCharlie for making this release happen
Migration notes
*Oftypes are kept as type aliases for the renamed data structures to simplify the migration, e.g.MapOfis an alias forMap.NewMapOfPresizedfunction is gone.NewMapcombined withWithPresizeshould be used instead.Map.Computemethod now expectsvalueFnto return aComputeOpvalue instead of a boolean flag. That's to support compute operation cancellation, so that the call does nothing.Map.LoadOrTryComputemethod is renamed toLoadOrCompute. The oldLoadOrComputemethod is removed as it was redundant.v3.5.1Compare Source
LoadOrComputeandLoadOrTryCompute#154v3.5.0Compare Source
SPSCQueue/SPSCQueueOf#152LoadOrTryComputemethod toMap/MapOf#153Thanks @mattjohnsonpint for suggesting the map enhancement.
v3.4.1Compare Source
ToPlainMap/ToPlainMapOfutility functions #151Thanks @KiddoV for suggesting this enhancement.
v3.4.0Compare Source
RBMutex#138 and #140Map/MapOfcapacity calculation forWithPresize#139RBMutexnow has methods for optimistic locking:Thanks @kkroo for the contribution.
v3.3.1Compare Source
NewMapOfWithHasherfunction #137Adds
NewMapOfWithHasherfunction to support custom hash functions inMapOf:Some custom hash functions may be faster than the built-in function if the lack of DDOS protection is fine.
Murmur3 finalizer:
Built-in hash function:
v3.3.0Compare Source
MapOflookups #134Map/MapOfstatistics #133Introduces meta memory and SWAR-based lookups similar to C++'s
absl::flat_hash_maphash table (https://abseil.io/docs/cpp/guides/container). The lookups are now up to 30% faster.Also, reduces
MapOf's memory overhead: each bucket now holds up to 5 entries instead of 3.Map/MapOfstatistics are available viam.Stats(). They may be used for diagnostic purposes.v3.2.0Compare Source
Adds options support to the
NewMap/NewMapOffunctions. AMapOfcan now be created like this:NewPresizedMap/NewPresizedMapOffunctions are deprecated. Use theWithPresizeoption instead.Also, adds
WithGrowOnlyoption. It configures newMap/MapOfinstance to be grow-only. This means that the underlying hash table grows in capacity when new keys are added, but does not shrink when keys are deleted. The only exception to this rule is theClearmethod which shrinks the hash table back to the initial capacity.Grow-only maps are more efficient in the case of oscillating map size, i.e. when the map frequently grows and then shrinks in size.
v3.1.0Compare Source
NewMapPresized/NewMapOfPresized's argument is now treated as the minimal table capacity. The underlying hash table won't shrink beyond the specified capacity.Also, fixes and improves godoc.
v3.0.2Compare Source
Thanks @mdumandag for reporting the issue.
v3.0.1Compare Source
Map/MapOfresize (#111)Thanks @klauspost for reporting this issue.
v3.0.0Compare Source
All
New*MapOf*functions are now replaced with theNewMapOfandNewMapOfPresizedfunctions. There is no longer a need to provide a user-defined hash function.Kudos go to @destel
v2.5.1Compare Source
v2.5.0Compare Source
MPMCQueueOf) (#104)v2.4.1Compare Source
v2.4.0Compare Source
MapandMapOf(#86)Map/MapOf.Range(#87 and #88)v2.3.2Compare Source
Thanks @felixge for holding a comprehensive (and lengthy) benchmarks run.
v2.3.1Compare Source
MapOfnow takes full advantage of Go generics: less GC pressure, less atomic operations on reads, also improved integer hash functionv2.3.0Compare Source
MapOfinteger hash function (#76)RBMutexfootprint and thread-to-slot distribution (#75)NewRBMutex()function must be called now to initialize aRBMutex.v2.2.0Compare Source
Counterthread-to-stripe distribution (#71 and #74)NewCounter()function must be called now to initialize aCounter.v2.1.0Compare Source
Thanks @psyhatter and @veqryn for the contribution.
v2.0.2Compare Source
v2.0.1Compare Source
v2.0.0Compare Source
MapOfAPI in favor of the standardhash/maphashpackage. The main difference is in thehasherargument expected in theNewTypedMapOffunction.Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.