Hitbox is an asynchronous caching framework supporting multiple backends and suitable for distributed and for single-machine applications.

Overview

hitbox

Build status Coverage Status

Hitbox is an asynchronous caching framework supporting multiple backends and suitable for distributed and for single-machine applications.

Framework integrations

Features

  • Automatic cache key generation.
  • Multiple cache backend implementations:
  • Stale cache mechanics.
  • Cache locks for dogpile effect preventions.
  • Distributed cache locks.
  • Detailed metrics out of the box.

Backend implementations

  • Redis
  • In-memory backend

Feature flags

  • derive - Support for Cacheable trait derive macros.
  • metrics - Support for metrics.

Restrictions

Default cache key implementation based on serde_qs crate and have some restrictions.

Documentation

Example

Dependencies:

[dependencies]
hitbox = "0.1"

Code:

First, you should derive Cacheable trait for your struct or enum:

use hitbox::prelude::*;
use serde::{Deserialize, Serialize};

#[derive(Cacheable, Serialize)] // With features=["derive"]
struct Ping {
    id: i32,
}

Or implement that trait manually:

String { "Ping".to_owned() } } ">
use hitbox::{Cacheable, CacheError};
struct Ping { id: i32 }
impl Cacheable for Ping {
    fn cache_key(&self) -> Result<String, CacheError> {
        Ok(format!("{}::{}", self.cache_key_prefix(), self.id))
    }

    fn cache_key_prefix(&self) -> String { "Ping".to_owned() }
}
Comments
  • Update serde_qs requirement from 0.8 to 0.9

    Update serde_qs requirement from 0.8 to 0.9

    Updates the requirements on serde_qs to permit the latest version.

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 2
  • Update actix requirement from 0.12 to 0.13

    Update actix requirement from 0.12 to 0.13

    Updates the requirements on actix to permit the latest version.

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 2
  • Update actix-web requirement from 3 to 4

    Update actix-web requirement from 3 to 4

    Updates the requirements on actix-web to permit the latest version.

    Release notes

    Sourced from actix-web's releases.

    actix-web: v4.0.1

    Fixed

    • Use stable version in readme example.
    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 2
  • Bump actions/checkout from 1 to 3

    Bump actions/checkout from 1 to 3

    Bumps actions/checkout from 1 to 3.

    Release notes

    Sourced from actions/checkout's releases.

    v3.0.0

    • Updated to the node16 runtime by default
      • This requires a minimum Actions Runner version of v2.285.0 to run, which is by default available in GHES 3.4 or later.

    v2.4.2

    What's Changed

    Full Changelog: https://github.com/actions/checkout/compare/v2...v2.4.2

    v2.4.1

    • Fixed an issue where checkout failed to run in container jobs due to the new git setting safe.directory

    v2.4.0

    • Convert SSH URLs like org-<ORG_ID>@github.com: to https://github.com/ - pr

    v2.3.5

    Update dependencies

    v2.3.4

    v2.3.3

    v2.3.2

    Add Third Party License Information to Dist Files

    v2.3.1

    Fix default branch resolution for .wiki and when using SSH

    v2.3.0

    Fallback to the default branch

    v2.2.0

    Fetch all history for all tags and branches when fetch-depth=0

    v2.1.1

    Changes to support GHES (here and here)

    v2.1.0

    ... (truncated)

    Changelog

    Sourced from actions/checkout's changelog.

    Changelog

    v3.0.2

    v3.0.1

    v3.0.0

    v2.3.1

    v2.3.0

    v2.2.0

    v2.1.1

    • Changes to support GHES (here and here)

    v2.1.0

    v2.0.0

    v2 (beta)

    • Improved fetch performance

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies github_actions 
    opened by dependabot[bot] 1
  • Bump codecov/codecov-action from 1 to 3

    Bump codecov/codecov-action from 1 to 3

    Bumps codecov/codecov-action from 1 to 3.

    Release notes

    Sourced from codecov/codecov-action's releases.

    v3.0.0

    Breaking Changes

    • #689 Bump to node16 and small fixes

    Features

    • #688 Incorporate gcov arguments for the Codecov uploader

    Dependencies

    • #548 build(deps-dev): bump jest-junit from 12.2.0 to 13.0.0
    • #603 [Snyk] Upgrade @​actions/core from 1.5.0 to 1.6.0
    • #628 build(deps): bump node-fetch from 2.6.1 to 3.1.1
    • #634 build(deps): bump node-fetch from 3.1.1 to 3.2.0
    • #636 build(deps): bump openpgp from 5.0.1 to 5.1.0
    • #652 build(deps-dev): bump @​vercel/ncc from 0.30.0 to 0.33.3
    • #653 build(deps-dev): bump @​types/node from 16.11.21 to 17.0.18
    • #659 build(deps-dev): bump @​types/jest from 27.4.0 to 27.4.1
    • #667 build(deps): bump actions/checkout from 2 to 3
    • #673 build(deps): bump node-fetch from 3.2.0 to 3.2.3
    • #683 build(deps): bump minimist from 1.2.5 to 1.2.6
    • #685 build(deps): bump @​actions/github from 5.0.0 to 5.0.1
    • #681 build(deps-dev): bump @​types/node from 17.0.18 to 17.0.23
    • #682 build(deps-dev): bump typescript from 4.5.5 to 4.6.3
    • #676 build(deps): bump @​actions/exec from 1.1.0 to 1.1.1
    • #675 build(deps): bump openpgp from 5.1.0 to 5.2.1

    v2.1.0

    2.1.0

    Features

    • #515 Allow specifying version of Codecov uploader

    Dependencies

    • #499 build(deps-dev): bump @​vercel/ncc from 0.29.0 to 0.30.0
    • #508 build(deps): bump openpgp from 5.0.0-5 to 5.0.0
    • #514 build(deps-dev): bump @​types/node from 16.6.0 to 16.9.0

    v2.0.3

    2.0.3

    Fixes

    • #464 Fix wrong link in the readme
    • #485 fix: Add override OS and linux default to platform

    Dependencies

    • #447 build(deps): bump openpgp from 5.0.0-4 to 5.0.0-5
    • #458 build(deps-dev): bump eslint from 7.31.0 to 7.32.0
    • #465 build(deps-dev): bump @​typescript-eslint/eslint-plugin from 4.28.4 to 4.29.1
    • #466 build(deps-dev): bump @​typescript-eslint/parser from 4.28.4 to 4.29.1
    • #468 build(deps-dev): bump @​types/jest from 26.0.24 to 27.0.0
    • #470 build(deps-dev): bump @​types/node from 16.4.0 to 16.6.0
    • #472 build(deps): bump path-parse from 1.0.6 to 1.0.7
    • #473 build(deps-dev): bump @​types/jest from 27.0.0 to 27.0.1

    ... (truncated)

    Changelog

    Sourced from codecov/codecov-action's changelog.

    3.1.0

    Features

    • #699 Incorporate xcode arguments for the Codecov uploader

    Dependencies

    • #694 build(deps-dev): bump @​vercel/ncc from 0.33.3 to 0.33.4
    • #696 build(deps-dev): bump @​types/node from 17.0.23 to 17.0.25
    • #698 build(deps-dev): bump jest-junit from 13.0.0 to 13.2.0

    3.0.0

    Breaking Changes

    • #689 Bump to node16 and small fixes

    Features

    • #688 Incorporate gcov arguments for the Codecov uploader

    Dependencies

    • #548 build(deps-dev): bump jest-junit from 12.2.0 to 13.0.0
    • #603 [Snyk] Upgrade @​actions/core from 1.5.0 to 1.6.0
    • #628 build(deps): bump node-fetch from 2.6.1 to 3.1.1
    • #634 build(deps): bump node-fetch from 3.1.1 to 3.2.0
    • #636 build(deps): bump openpgp from 5.0.1 to 5.1.0
    • #652 build(deps-dev): bump @​vercel/ncc from 0.30.0 to 0.33.3
    • #653 build(deps-dev): bump @​types/node from 16.11.21 to 17.0.18
    • #659 build(deps-dev): bump @​types/jest from 27.4.0 to 27.4.1
    • #667 build(deps): bump actions/checkout from 2 to 3
    • #673 build(deps): bump node-fetch from 3.2.0 to 3.2.3
    • #683 build(deps): bump minimist from 1.2.5 to 1.2.6
    • #685 build(deps): bump @​actions/github from 5.0.0 to 5.0.1
    • #681 build(deps-dev): bump @​types/node from 17.0.18 to 17.0.23
    • #682 build(deps-dev): bump typescript from 4.5.5 to 4.6.3
    • #676 build(deps): bump @​actions/exec from 1.1.0 to 1.1.1
    • #675 build(deps): bump openpgp from 5.1.0 to 5.2.1

    2.1.0

    Features

    • #515 Allow specifying version of Codecov uploader

    Dependencies

    • #499 build(deps-dev): bump @​vercel/ncc from 0.29.0 to 0.30.0
    • #508 build(deps): bump openpgp from 5.0.0-5 to 5.0.0
    • #514 build(deps-dev): bump @​types/node from 16.6.0 to 16.9.0

    2.0.3

    Fixes

    • #464 Fix wrong link in the readme
    • #485 fix: Add override OS and linux default to platform

    Dependencies

    • #447 build(deps): bump openpgp from 5.0.0-4 to 5.0.0-5

    ... (truncated)

    Commits
    • 81cd2dc Merge pull request #699 from codecov/feat-xcode
    • a03184e feat: add xcode support
    • 6a6a9ae Merge pull request #694 from codecov/dependabot/npm_and_yarn/vercel/ncc-0.33.4
    • 92a872a Merge pull request #696 from codecov/dependabot/npm_and_yarn/types/node-17.0.25
    • 43a9c18 Merge pull request #698 from codecov/dependabot/npm_and_yarn/jest-junit-13.2.0
    • 13ce822 Merge pull request #690 from codecov/ci-v3
    • 4d6dbaa build(deps-dev): bump jest-junit from 13.0.0 to 13.2.0
    • 98f0f19 build(deps-dev): bump @​types/node from 17.0.23 to 17.0.25
    • d3021d9 build(deps-dev): bump @​vercel/ncc from 0.33.3 to 0.33.4
    • 2c83f35 Update makefile to v3
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies github_actions 
    opened by dependabot[bot] 1
  • Bump supercharge/redis-github-action from 1.2.0 to 1.4.0

    Bump supercharge/redis-github-action from 1.2.0 to 1.4.0

    Bumps supercharge/redis-github-action from 1.2.0 to 1.4.0.

    Changelog

    Sourced from supercharge/redis-github-action's changelog.

    1.4.0 - 2021-12-28

    Added

    • use a custom name for the Redis container: this is helpful when starting multiple Redis instances

    1.3.0 - 2021-12-27

    Added

    • start Redis instance on a custom port
    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies github_actions 
    opened by dependabot[bot] 1
  • Update serde_qs requirement from 0.8 to 0.10

    Update serde_qs requirement from 0.8 to 0.10

    Updates the requirements on serde_qs to permit the latest version.

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 1
  • Update tracing-subscriber requirement from 0.2 to 0.3

    Update tracing-subscriber requirement from 0.2 to 0.3

    Updates the requirements on tracing-subscriber to permit the latest version.

    Release notes

    Sourced from tracing-subscriber's releases.

    tracing-subscriber v0.3.0

    0.3.0 (Oct 22, 2021)

    This is a breaking release of tracing-subscriber. The primary breaking change in this release is the removal of the dependency on the [chrono crate], due to [RUSTSEC-2020-0159]. To replace chrono, support is added for formatting timestamps using the [time crate] instead.

    In addition, this release includes a number of other breaking API changes, such as adding (limited) support for #![no_std] targets, removing previously deprecated APIs, and more.

    Breaking Changes

    • Removed APIs deprecated in the v0.2.x release series.

    • Renamed Layer::new_span to Layer::on_new_span (#1674)

    • Removed Layer impl for Arc<L: Layer<S>> and Arc<dyn Layer<S> + ...> (#1649)

    • Replaced the [chrono crate] with the [time crate] for timestamp formatting, to resolve [RUSTSEC-2020-0159] (#1646)

    • Removed json and env-filter from default features. They must now be enabled explicitly (#1647)

    • Changed FormatEvent::format_event and FormatFields::format_fields trait methods to take a Writer type, rather than a &mut dyn fmt::Write trait object (#1661)

    • Changed the signature of the MakeWriter trait by adding a lifetime parameter (#781)

      Changed

    • layer: Renamed Layer::new_span to Layer::on_new_span (#1674)

    • fmt: Changed FormatEvent::format_event and FormatFields::format_fields trait methods to take a Writer type, rather than a &mut dyn fmt::Write trait object (#1661)

    • json, env-filter: json and env-filter feature flags are no longer enabled by default (#1647)

      Removed

    • Removed deprecated CurrentSpan type (#1320)

    • registry: Removed deprecated SpanRef::parents iterator, replaced by SpanRef::scope in #1431 ([#1648)])

    • layer: Removed deprecated Context::scope iterator, replaced by Context::span_scope and Context::event_scope in #1431 and #1434 (#1648)

    • layer: Removed Layer impl for Arc<L: Layer<S>> and Arc<dyn Layer<S> + ...>. These interfere with per-layer filtering. (#1649)

    • fmt: Removed deprecated LayerBuilder type (#1673)

    • fmt: Removed fmt::Layer::on_event (renamed to fmt::Layer::fmt_event) (#1673)

    ... (truncated)

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 1
  • Update redis requirement from 0.20 to 0.21

    Update redis requirement from 0.20 to 0.21

    Updates the requirements on redis to permit the latest version.

    Changelog

    Sourced from redis's changelog.

    0.20.0 (2021-07-16)

    Performance

    • Don't enqueue multiplexed commands if the receiver is dropped (ca5019db)

    Features

    • Refactor ConnectionAddr to remove boxing and clarify fields

    0.20.2 (2021-06-17)

    Features

    • Provide a new_async_std function (c3716d15)

    Bug Fixes

    • Return Ready(Ok(())) when we have flushed all messages (ca319c06)
    • Don't loop forever on shutdown of the multiplexed connection (ddecce9e)

    0.20.1 (2021-05-18)

    Bug Fixes

    • Error properly if eof is reached in the decoder (306797c3)

    0.20.0 (2021-02-17)

    Features

    • Make ErrorKind non_exhaustive for forwards compatibility (ac5e1a60)
    • aio: Allow the underlying IO stream to be customized (6d2fc8fa)

    0.19.0 (2020-12-26)

    ... (truncated)

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 1
  • Update env_logger requirement from 0.8 to 0.9

    Update env_logger requirement from 0.8 to 0.9

    Updates the requirements on env_logger to permit the latest version.

    Release notes

    Sourced from env_logger's releases.

    v0.9.0

    Breaking Changes:

    • Default message format now prints the target instead of the module

    Improvements:

    • Added a method to print the module instead of the target
    Commits
    • 04856ac bump version to 0.9.0
    • e4744ff Merge pull request #209 from gtsiam/main
    • c5fa7a2 refactor: fix clippy warnings
    • 34574df Update link to examples
    • 1888497 Clarified documentation about log filtering
    • 365ffaf Show target instead of module path by default
    • d2998a6 Add option to print log target
    • 13cafce Bump version to 0.8.4
    • 0900811 Ensure unique directive names when building filters
    • 1a8379a Allow writing logs to a custom output target (Target::Pipe)
    • Additional commits viewable in compare view

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 1
  • Update prometheus requirement from 0.12 to 0.13

    Update prometheus requirement from 0.12 to 0.13

    Updates the requirements on prometheus to permit the latest version.

    Changelog

    Sourced from prometheus's changelog.

    0.13.0

    • Bug fix: Avoid panics from Instant::elapsed (#406)

    • Improvement: Allow trailing comma on macros (#390)

    • Improvement: Add macros for custom registry (#396)

    • Improvement: Export thread count from process_collector (#401)

    • Improvement: Add convenience TextEncoder functions to encode directly to string (#402)

    • Internal change: Clean up the use of macro_use and extern crate (#398)

    • Internal change: Update dependencies

    0.12.0

    • Improvement: Fix format string in panic!() calls (#391)

    • Improvement: Replace regex with memchr (#385)

    • Improvement: Update reqwest requirement from ^0.10 to ^0.11 (#379)

    0.11.0

    • Improvement: Switch to more efficient fd_count() for process_open_fds (#357).

    • API change: Change Integer Counter type from AtomicI64 to AtomicU64 (#365).

    • Internal change: Update dependencies.

    0.10.0

    • Improvement: Use different generic parameters for name and help at metric construction (#324).

    • Bug fix: Error instead of panic when constructing histogram with unequal label key and label value length (#326).

    • Bug fix: Return Error::AlreadyReg on duplicate collector registration (#333).

    • Bug fix: Make Histogram::observe atomic across collects (#314).

    • Internal change: Replace spin with parking_lot (#318).

    • Internal change: Optimize metric formatting (#327).

    • Internal change: Update parking_lot and procfs dependencies (#337).

    0.9.0

    ... (truncated)

    Commits
    • fe0a284 prometheus: release 0.13.0 (#415)
    • 3451d05 Allow trailing comma on macros (#390)
    • 1e92ec7 build(deps): update procfs requirement from ^0.9 to ^0.10 (#408)
    • 1533b1a feat(macros): add macros for custom registry (#396)
    • fab7e76 Export thread count from process_collector (#401)
    • a93ed8c Avoid panics from Instant::elapsed (#406)
    • 9bbd908 Add convenience TextEncoder functions to encode directly to string (#402)
    • bb90a19 ci: update linting toolchain to 1.53 (#403)
    • 1e7736f Clean up the use of macro_use and extern crate (#398)
    • See full diff in compare view

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies 
    opened by dependabot[bot] 0
  • Update env_logger requirement from 0.9.0 to 0.10.0

    Update env_logger requirement from 0.9.0 to 0.10.0

    Updates the requirements on env_logger to permit the latest version.

    Changelog

    Sourced from env_logger's changelog.

    0.10.0 - 2022-11-24

    MSRV changed to 1.60 to hide optional dependencies

    Fixes

    • Resolved soundness issue by switching from atty to is-terminal

    Breaking Changes

    To open room for changing dependencies:

    • Renamed termcolor feature to color
    • Renamed atty feature to auto-color

    0.9.3 - 2022-11-07

    • Fix a regression from v0.9.2 where env_logger would fail to compile with the termcolor feature turned off.

    0.9.2 - 2022-11-07

    • Fix and un-deprecate Target::Pipe, which was basically not working at all before and deprecated in 0.9.1.

    0.9.0 -- 2022-07-14

    Breaking Changes

    • Default message format now prints the target instead of the module

    Improvements

    • Added a method to print the module instead of the target
    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies rust 
    opened by dependabot[bot] 0
  • Update redis requirement from 0.21 to 0.22

    Update redis requirement from 0.21 to 0.22

    Updates the requirements on redis to permit the latest version.

    Release notes

    Sourced from redis's releases.

    v0.22.0

    Redis-rs is a high level redis library for Rust and aims to provide convenient access to all Redis functionality through a very flexible but low-level API. The crate has recently come under maintainership by @​djc and @​jaymell. Much appreciation and many thanks to @​mitsuhiko, @​badboy, @​Marwes for their work in building this library over the years! The new maintainers hope to improve the velocity of bug fixes, new features, and PR reviews in the coming months.

    This release adds various incremental improvements, including additional convenience commands, improved Cluster APIs, and various other bug fixes/library improvements.

    Although the changes here are incremental, this is a major release due to the breaking changes listed below.

    This release would not be possible without our many wonderful contributors -- thank you!

    Breaking changes

    • Box all large enum variants; changes enum signature (#667 @​nihohit)
    • Support ACL commands by adding Rule::Other to cover newly defined flags; adds new enum variant (#685 @​garyhai)
    • Switch from sha1 to sha1_smol; renames sha1 feature (#576)

    Features

    Changes

    • Rust 2021 Edition / MSRV 1.59.0
    • Fix: Support IPV6 link-local address parsing (#679 @​buaazp)
    • Derive Clone and add Deref trait to InfoDict (#661 @​danni-m)
    • ClusterClient: add handling for empty initial_nodes, use ClusterParams to store cluster parameters, improve builder pattern (#669 @​utkarshgupta137)
    • Implement Debug for MultiplexedConnection & Pipeline (#664 @​elpiel)
    • Add support for casting RedisResult to CString (#660 @​nihohit)
    • Move redis crate to subdirectory to support multiple crates in project (#465 @​tdyas)
    • Stop versioning Cargo.lock (#620)
    • Auto-implement ConnectionLike for DerefMut (#567 @​holmesmr)
    • Return errors from parsing inner items (#608)
    • Make dns resolution async, in async runtime (#606 @​roger)
    • Make async_trait dependency optional (#572 @​kamulos)
    • Add username to ClusterClient and ClusterConnection (#596 @​gildaf)
    Commits
    • 175395e Release redis-0.22.0 / redis-test-0.1.0
    • 0da6040 Update version numbers in code samples.
    • 0c6b9ec Merge branch '0.21.x'
    • c14b73f Add Rule::Other to cover newly defined flags. #682 (#685)
    • dbe4290 Fix changelog for 0.21.6
    • 79fde68 Support ipv6 connect
    • 0302280 Derive Clone and add Deref trait to InfoDict (#661)
    • 2559af6 Update changelog for 0.21.6
    • 27dbad5 Run CI for 0.21.x maintenance branch
    • 0e84d73 Make Direction a public enum to use with Commands like blmove (#646)
    • Additional commits viewable in compare view

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    dependencies rust 
    opened by dependabot[bot] 1
  • feat/container

    feat/container

    Hey guys. I think, that Cacheable derive attributes, collected in one place, makes derive more scalable, easier for future support and hitbox namespace will allow you to more accurately determine the necessary attributes. Also it makes errors more understandable.

    #[derive(Message, Cacheable, Serialize)]
    #[hitbox(cache_ttl="str")]
    #[rtype(result = "u64")]
    struct GetNumber {
        number: u8,
    }
    
    error: Expected hitbox cache_ttl attribute should be u32
      --> src/main.rs:24:20
       |
    24 | #[hitbox(cache_ttl="str")]
       |                    ^^^^^
    

    Instead of

    #[derive(Message, Cacheable, Serialize)]
    #[cache_ttl("str")]
    #[rtype(result = "u64")]
    struct GetNumber {
        number: u8,
    }
    
    error: proc-macro derive panicked
      --> src/main.rs:23:19
       |
    23 | #[derive(Message, Cacheable, Serialize)]
       |                   ^^^^^^^^^
       |
       = help: message: Parameter for macro cache_ttl should be u32
    

    What do you think about it?

    opened by topenkoff 0
  • Instance based cache locks

    Instance based cache locks

    Cache locks are the main protection from the dogpile effect. As main functionality (not related to some backend implementation) I suppose next simple structure.

    Use something like a HasMap<&str, AsyncRwLock<CachedValue>> where the key is a cache key of the current request and AsyncRWLock is an async version of classic RwLock (or some light pub-sub mechanic like tokio watch or one-shot channels).

    How it should work:

    1. First request with cache key A to Upstream will create a record in a Hash table. and send a request to Upstream
    2. Second and next requests to Upstream with cache key A will check records on the hash table and subscribe to value changes (or asynchronous wait for changes)
    3. After first request will be resolved in Upstream cache should publish result to all consumers/waiters and remove record from HashMap
    enhancement cache locks 
    opened by singulared 0
  • Distributed cache backend support

    Distributed cache backend support

    Redis cluster is a good candidate for distributed cache backend in MVP. But we need to finish some related issues:

    • #17
    • Add redis-cluster backend instead of a current single instance backend
    enhancement backend 
    opened by singulared 0
Releases(hitbox-redis-0.1.1)
Owner
null
Solana JSON-RPC caching server

Solana JSON-RPC caching server Disclaimer: This project is an early stage Work-In-Progress and is not ready for production use. This cache server impl

ZUBR 61 Dec 16, 2022
Attribute-Level Caching in Heterogeneous In-Memory DBMS

Alchemy Attribute-Level Caching in Heterogeneous In-Memory DBMS Alchemy is a DRAM-PM hybrid database engine built from scratch to achieve high perform

Xiangpeng Hao 14 Jun 20, 2022
A general-purpose distributed memory cache system compatible with Memcached

memcrsd memcached server implementation in Rust memcrsd is a key value store implementation in Rust. It is compatible with binary protocol of memcache

null 274 Dec 14, 2022
Non-volatile, distributed file cache backed by content-addressed storage

blobnet A low-latency file server that responds to requests for chunks of file data. This acts as a non-volatile, over-the-network content cache. Inte

Modal Labs 12 Dec 31, 2022
Rust cache structures and easy function memoization

cached Caching structures and simplified function memoization cached provides implementations of several caching structures as well as a handy macro f

James Kominick 996 Jan 7, 2023
This is a Rust implementation for HashiCorp's golang-lru. This crate contains three LRU based cache, LRUCache, TwoQueueCache and AdaptiveCache.

This is a Rust implementation for HashiCorp's golang-lru. This crate contains three LRU based cache, LRUCache, TwoQueueCache and AdaptiveCache.

Al Liu 84 Jan 3, 2023
TUI input library supporting multiple backends

tui-input WARNING: Most of the functionality is only human tested. A TUI input library supporting multiple backends. This crate can be used with tui-r

Arijit Basu 36 Dec 19, 2022
Simple and flexible queue implementation for Rust with support for multiple backends (Redis, RabbitMQ, SQS, etc.)

Omniqueue Omniqueue is an abstraction layer over queue backends for Rust. It includes support for RabbitMQ, Redis streams, and SQS out of the box. The

Svix 8 May 26, 2023
Single-reader, multi-writer & single-reader, multi-verifier; broadcasts reads to multiple writeable destinations in parallel

Bus Writer This Rust crate provides a generic single-reader, multi-writer, with support for callbacks for monitoring progress. It also provides a gene

Pop!_OS 26 Feb 7, 2022
Easy c̵̰͠r̵̛̠ö̴̪s̶̩̒s̵̭̀-t̶̲͝h̶̯̚r̵̺͐e̷̖̽ḁ̴̍d̶̖̔ ȓ̵͙ė̶͎ḟ̴͙e̸̖͛r̶̖͗ë̶̱́ṉ̵̒ĉ̷̥e̷͚̍ s̷̹͌h̷̲̉a̵̭͋r̷̫̊ḭ̵̊n̷̬͂g̵̦̃ f̶̻̊ơ̵̜ṟ̸̈́ R̵̞̋ù̵̺s̷̖̅ţ̸͗!̸̼͋

Rust S̵̓i̸̓n̵̉ I̴n̴f̶e̸r̵n̷a̴l mutability! Howdy, friendly Rust developer! Ever had a value get m̵̯̅ð̶͊v̴̮̾ê̴̼͘d away right under your nose just when

null 294 Dec 23, 2022
A single-threaded polling-based Rust async executor suitable for use in games, embedded systems or WASM.

simple async local executor An Enlightware® software. Overview A single-threaded polling-based executor suitable for use in games, embedded systems or

Enlightware GmbH 16 Nov 15, 2022
A buildpack for Rust applications on Heroku, with full support for Rustup, cargo and build caching.

Heroku buildpack for Rust This is a Heroku buildpack for Rust with support for cargo and rustup. Features include: Caching of builds between deploymen

Eric Kidd 502 Nov 7, 2022
ReadySet is a lightweight SQL caching engine written in Rust that helps developers enhance the performance and scalability of existing applications.

ReadySet is a SQL caching engine designed to help developers enhance the performance and scalability of their existing database-backed applications. W

ReadySet 1.7k Jan 8, 2023
Jamsocket is a lightweight framework for building WebSocket-based application backends.

Jamsocket is a lightweight framework for building services that are accessed through WebSocket connections.

null 94 Dec 30, 2022
A lightweight framework for building WebSocket-based application backends.

Jamsocket Jamsocket is a lightweight framework for building services that are accessed through WebSocket connections. Services can either be native Ru

drifting in space 94 Dec 30, 2022
CarLI is a framework for creating single-command and multi-command CLI applications in Rust

CarLI is a framework for creating single-command and multi-command CLI applications in Rust. The framework provides error and IO types better suited for the command line environment, especially in cases where unit testing is needed.

Kevin Herrera 3 Jan 21, 2022
A versatile and efficient proxy framework with nice features suitable for various use cases.

A versatile and efficient proxy framework with nice features suitable for various use cases.

null 1.7k Jan 9, 2023
open source training courses about distributed database and distributed systemes

Welcome to learn Talent Plan Courses! Talent Plan is an open source training program initiated by PingCAP. It aims to create or combine some open sour

PingCAP 8.3k Dec 30, 2022
Damavand is a quantum circuit simulator. It can run on laptops or High Performance Computing architectures, such CPU distributed architectures or multi GPU distributed architectures.

Damavand is a quantum circuit simulator. It can run on laptops or High Performance Computing architectures, such CPU distributed architectures or multi GPU distributed architectures.

MichelNowak 0 Mar 29, 2022
Damavand is a quantum circuit simulator. It can run on laptops or High Performance Computing architectures, such CPU distributed architectures or multi GPU distributed architectures.

Damavand is a code that simulates quantum circuits. In order to learn more about damavand, refer to the documentation. Development status Core feature

prevision.io 6 Mar 29, 2022