Skip to content

Update Rust crate moka to v0.12.16 - #15

Open
konflux-staging[bot] wants to merge 1 commit into
mainfrom
konflux/mintmaker/main/moka-0.x-lockfile
Open

Update Rust crate moka to v0.12.16#15
konflux-staging[bot] wants to merge 1 commit into
mainfrom
konflux/mintmaker/main/moka-0.x-lockfile

Conversation

@konflux-staging

@konflux-staging konflux-staging Bot commented Sep 20, 2025

Copy link
Copy Markdown

This PR contains the following updates:

Package Type Update Change
moka dependencies patch 0.12.80.12.16

Release Notes

moka-rs/moka (moka)

v0.12.16

Compare Source

Fixed
  • Fixed a bug where cache eviction could stall permanently when the cache was
    configured with the non-default LRU eviction policy (EvictionPolicy::lru())
    by a race between insert and remove operations on the same key
    ([#​592][gh-pull-0592] by [@​kim-jhyeon][gh-kim-jhyeon], reported in
    [#​590][gh-issue-0590]):
    • This bug was introduced in v0.12.0 and affected sync::Cache,
      sync::SegmentedCache and future::Cache.
    • A race between applying a write recording for an entry and concurrently
      removing that entry from the internal concurrent hash table could leave an
      orphaned node at the front of the LRU queue. Once present, no entry was ever
      evicted again and the cache grew unboundedly past max_capacity.
    • The same race also affected the default TinyLFU eviction policy, but with
      a milder symptom: each occurrence permanently leaked one phantom entry
      slot, causing entry_count and weighted_size to over-report and the
      usable capacity to shrink by one entry per occurrence. Fixed by the same
      change.
Changed
  • Worked around a ThreadSanitizer false positive ([#​602][gh-pull-0602]):
    • Replaced the standalone fence(Acquire) in the internal MiniArc's drop
      path with an Acquire load of the reference count, so that downstream
      projects can now run ThreadSanitizer on code using Moka without hitting
      this false positive.
    • std::sync::Arc has a similar workaround.
  • Raised the minimum version of the crossbeam-epoch crate from v0.9.18 to
    v0.9.20 to avoid the following advisory ([#​603][gh-pull-0603]):
    • [RUSTSEC-2026-0204] crossbeam-epoch: invalid pointer dereference in
      fmt::Pointer for Atomic and Shared
    • Moka is not affected by this advisory because it never formats these
      pointer types. However, raising the minimum version prevents downstream
      lockfiles from resolving to an affected crossbeam-epoch version via
      Moka.

v0.12.15

Compare Source

Fixed
  • Fixed a bug where re-inserting an expired entry could cause it to lose its
    expiration time and remain in the cache indefinitely when using a custom Expiry
    policy with per-entry expiration. ([#​582][gh-pull-0582] by [@​jiangzhe][gh-jiangzhe],
    [#​581][gh-pull-0581] by [@​atrocities][gh-atrocities], reported in
    [#​575][gh-issue-0575]):
    • This occurred when an entry that had expired but not yet been evicted was
      re-inserted, and expire_after_update returned None. This primarily
      affected users who only override expire_after_create, since the default
      expire_after_update returns duration_until_expiry, which is None for
      expired entries.
    • This bug was introduced by the changes in v0.12.13 ([#​549][gh-pull-0549] and
      [#​564][gh-pull-0564]).
    • Subtle behavior change:
      • Before this fix, re-inserting an expired entry was treated as an update,
        so Expiry::expire_after_update was called.
      • After this fix, re-inserting an expired entry is treated as a creation,
        so Expiry::expire_after_create is called instead.
      • This may change the expiration time of re-inserted entries, depending on
        your Expiry trait implementation.
  • Fixed flaky tests cht::segment::tests::drop_many_values and
    drop_many_values_concurrent that were failing on high-core-count machines
    ([#​586][gh-pull-0586]):
    • These tests were using a CPU-dependent segment count, causing inconsistent
      bucket array shrinking behavior of the internal segmented hash map across
      different machines.
    • Changed these tests to use a fixed segment count (4) for consistent results.
Changed
  • Disabled flaky GC-dependent tests by default using run_flaky_tests cfg
    ([#​584][gh-pull-0584]):
    • These tests rely on epoch-based garbage collection (crossbeam-epoch) timing
      that is not guaranteed, causing intermittent failures.
    • Fixed [#​539][gh-issue-0539] and [#​580][gh-issue-0580].
    • To run these tests, set RUSTFLAGS='--cfg run_flaky_tests'.

v0.12.14

Compare Source

Fixed
  • Fixed a race condition in the and_compute_with method in the future::Cache.
    ([#​574][gh-pull-0574] by [@​Squadrick][gh-Squadrick]):
    • When multiple calls are made concurrently for the same key, the f closure may
      read a stale value, causing the first update to be lost when it is overwritten
      by a later one.
Changed

v0.12.13

Compare Source

Fixed
  • Fixed/mitigated use-after-free issues in the hierarchical timer wheels when Expiry
    returns None (Issue [#​565][gh-issue-0565], reported by
    [@​sharksforarms][gh-sharksforarms]).
    • Fixed a bug that caused freed timer nodes to remain in the timer wheels in
      some edge cases ([#​566][gh-pull-0566] by [@​powergee][gh-powergee]).
    • The mitigation added to v0.12.12 was enhanced by atomically reading the
      expiration state to prevent rare race conditions that could cause use-after-free
      issues ([#​570][gh-pull-0570]).
  • Fixed Expiry::expire_after_update not clearing expiration time for expired entries
    (future::Cache: [#​549][gh-pull-0549], by [@​singulared][gh-singulared],
    sync::Cache: [#​564][gh-pull-0564]).

v0.12.12

Compare Source

Bumped the minimum supported Rust version (MSRV) to 1.71.1, released on August 3,
2023 ([#​555][gh-pull-0555]).

Fixed
  • Mitigated use-after-free issues in the hierarchical timer wheels when Expiry
    returns None ([#​548][gh-pull-0548], by [@​awarus][gh-awarus]).
  • Fixed a subtle undefined behavior in the internal deque::move_to_back method
    (found by Miri) ([#​553][gh-pull-0553]).
Added
Removed
  • Removed several unneeded files from the published package ([#​541][gh-pull-0541],
    by [@​weiznich][gh-weiznich]).
  • Removed the once_cell crate from the dependencies ([#​520][gh-pull-0520], by
    [@​Expyron][gh-Expyron]).
  • Removed the rustc_version crate from the dev-dependencies ([#​554][gh-pull-0554]).

v0.12.11

Compare Source

Breaking Changes
  • After releasing v0.12.11, we found that supporting Equivalent trait was an
    unintended breaking change.
    • If you get a compilation error something like following, please update your
      code to reborrow the key like &*key.
      • error[E0277]: the trait bound `T: Borrow<Arc<T>>` is not satisfied
        ...
        = note: required for `Arc<T>` to implement `Equivalent<T>`
    • See this PR comment for more details.
Added
  • Support Equivalent trait for the key type K of the caches.
    ([#​492][gh-pull-0492])
  • Added the jittered_expiry_policy example ([#​489][gh-pull-0489]).
Changed
  • Adjusted license expression: some code is Apache-2.0 only ([#​529][gh-pull-0529], by
    [@​musicinmybrain][gh-musicinmybrain]).
    • The license expression in Cargo.toml was changed from
      MIT OR Apache-2.0 to (MIT OR Apache-2.0) AND Apache-2.0.
    • See the license section of the README for details.
  • Upgrading a crate in the dependencies:
    • Raised the minimum version of crossbeam-channel crate from v0.5.5 to
      v0.5.15 to avoid the following issue ([#​514][gh-pull-0514],
      by [karankurbur][gh-karankurbur]).
      • [RUSTSEC-2025-0024] crossbeam-channel: double free on Drop
  • Moving a crate from the dependencies to the dev-dependencies:
    • Switched loom crate to a dev-dependency
      ([#​509][gh-pull-0509], by [thomaseizinger][gh-thomaseizinger]).
  • Updating a crate in the dev-dependencies:
    • Upgraded reqwest crate in the dev-dependencies from v0.11 to v0.12
      ([#​531][gh-pull-0531], by [musicinmybrain][gh-musicinmybrain]).
Removed
  • Removing a crate from the dependencies:
    • Removed thiserror crate by manually implementing std::error::Error for
      moka::PredicateError ([#​512][gh-pull-0512], by [@​brownjohnf][gh-brownjohnf]).
  • Removing crates from the dev-dependencies:
    • Removed unmaintained paste crate from the dev-dependencies ([#​504][gh-pull-0504]).
      • [RUSTSEC-2024-0436] paste - no longer maintained
    • Removed discontinued async-std crate from the dev-dependencies ([#​534][gh-pull-0534]).
      • [RUSTSEC-2025-0052] async-std has been discontinued
  • Removed clippy ignore non_send_fields_in_send_ty that no longer applies
    ([#​505][gh-pull-0505], by [@​qti3e][gh-qti3e]).
Fixed
  • Remove redundant word in source code comment ([#​532][gh-pull-0532],
    by [@​quantpoet][gh-quantpoet]).

v0.12.10

Compare Source

Changed
  • Disabled the quanta feature by default. ([#​482][gh-pull-0482])
  • Replaced most uses of quanta::Instant with std::time::Instant to increase the
    accuracy of time measurements ([#​481][gh-pull-0481]):
    • When quanta feature is enabled, quanta::Instant is used for some
      performance critical parts in the cache, and std::time::Instant is used for
      the rest of the parts.
    • However, as of this version, enabling the quanta feature will not make any
      noticeable difference in the performance.
    • When quanta feature is disabled (default), std::time::Instant is used for
      all time measurements.
  • Switched to AtomicU64 of the portable-atomic crate, which provides fallback
    implementations for platforms where std AtomicU64 is not available
    ([#​480][gh-pull-0480]):
    • moka's atomic64 feature no longer has any effect on the build as
      AtomicU64 is now always available on all platforms. But we keep the
      atomic64 feature in Cargo.toml for backward compatibility.

v0.12.9

Compare Source

Bumped the minimum supported Rust version (MSRV) to 1.70 (June 1, 2023)
([#​474][gh-pull-0474]).

Fixed
  • Prevent an occasional panic in an internal to_std_instant method when per-entry
    expiration policy is used. ([#​472][gh-issue-0472])
  • Documentation: Removed leftover mentions of background threads.
    ([#​464][gh-issue-0464])
    • Also added the implementation details chapter to the crate top-level
      documentation to explain some internal behavior of the cache.
Added
  • Added and_try_compute_if_nobody_else method to future::Cache's entry API.
    ([#​460][gh-pull-0460], by [@​xuehaonan27][gh-xuehaonan27])
Removed
  • Removed triomphe crate from the dependency by adding our own internal Arc type.
    ([#​456][gh-pull-0456])
    • Our Arc will be more memory efficient than std::sync::Arc or
      triomphe::Arc on 64-bit platforms as it uses a single AtomicU32 counter.
  • Removed needless traits along with async-trait usage. ([#​445][gh-pull-0445], by
    [@​Swatinem][gh-Swatinem])
Changed
  • Enable atomic64 feature only when target supports AtomicU64.
    ([#​466][gh-pull-0466], by [@​zonyitoo][gh-zonyitoo])
  • Made once_cell dependency optional ([#​444][gh-pull-0444]).
  • Stopped creating references unnecessarily to compare pointers by-address.
    ([#​452][gh-pull-0452], by [@​JoJoDeveloping][gh-JoJoDeveloping])

Configuration

📅 Schedule: (UTC)

  • 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.


  • If you want to rebase/retry this PR, check this box

To execute skipped test pipelines write comment /ok-to-test.


Documentation

Find out how to configure dependency updates in MintMaker documentation or see all available configuration options in Renovate documentation.

@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from 401afc6 to 4f00c28 Compare September 23, 2025 20:14
@konflux-staging konflux-staging Bot changed the title fix(deps): update rust crate moka to v0.12.10 fix(deps): update rust crate moka to v0.12.11 Sep 23, 2025
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from 4f00c28 to 39da8b9 Compare December 21, 2025 12:16
@konflux-staging konflux-staging Bot changed the title fix(deps): update rust crate moka to v0.12.11 fix(deps): update rust crate moka to v0.12.12 Dec 21, 2025
@konflux-staging konflux-staging Bot changed the title fix(deps): update rust crate moka to v0.12.12 chore(deps): update rust crate moka to v0.12.12 Jan 12, 2026
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from 39da8b9 to ec2936e Compare January 26, 2026 08:12
@konflux-staging konflux-staging Bot changed the title chore(deps): update rust crate moka to v0.12.12 chore(deps): update rust crate moka to v0.12.13 Jan 26, 2026
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from ec2936e to f8fc901 Compare March 2, 2026 04:12
@konflux-staging konflux-staging Bot changed the title chore(deps): update rust crate moka to v0.12.13 chore(deps): update rust crate moka to v0.12.14 Mar 2, 2026
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from f8fc901 to f6878f1 Compare March 22, 2026 08:22
@konflux-staging konflux-staging Bot changed the title chore(deps): update rust crate moka to v0.12.14 chore(deps): update rust crate moka to v0.12.15 Mar 22, 2026
@konflux-staging konflux-staging Bot changed the title chore(deps): update rust crate moka to v0.12.15 Update Rust crate moka to v0.12.15 Jun 16, 2026
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from f6878f1 to 5e27990 Compare August 11, 2026 17:32
Signed-off-by: konflux-staging <124796549+konflux-staging[bot]@users.noreply.github.com>
@konflux-staging
konflux-staging Bot force-pushed the konflux/mintmaker/main/moka-0.x-lockfile branch from 5e27990 to a6fff4d Compare August 13, 2026 00:18
@konflux-staging konflux-staging Bot changed the title Update Rust crate moka to v0.12.15 Update Rust crate moka to v0.12.16 Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants