©️
Cross api
En-US
En-US
  • Introduction
  • Compatibility
  • Extensions
  • Usage
    • Tools
      • Config
      • ListProvider
      • Language
      • Help
    • Structure
      • MakeApi
      • MakeModule
      • MakeProvider
      • Revert
  • Structure
    • Root
    • Src
    • @Types
    • Assets
    • Config
    • Dtos
    • Jobs
    • Keys
    • Middlewares
    • Modules
    • Routes
    • Shared
    • Utils
  • Services
    • Transactions
    • Exists
    • FindBy
    • FindIn
    • FindLike
    • FindAll
    • Create
    • CreateMany
    • Update
    • UpdateMany
    • Delete
    • DeleteMany
    • SoftDelete
    • SoftDeleteMany
  • Mappers
    • CloneAttribute
    • UpdateAttribute
    • PatchAttribute
    • UpdateString
    • PatchString
    • InsertAttribute
  • Providers
    • Cache
    • Crypto
    • Hash
    • Lead
    • MailTemplate
    • Mail
    • Queue
    • Notification
    • Storage
Powered by GitBook
On this page
  • Available:
  • Methods:

Was this helpful?

  1. Providers

Cache

A caching implementation to make the system more fluid and not always rely on SQL operations.

Available:

  • Redis

  • Fake

Methods:

Save: Caches a value passed in a key.

const data = { message: 'data' };

await this.cacheProvider.save('key:id=123', data);

Recovery: Retrieves cached data from a key.

const data = await this.cacheProvider.recovery('key:id=123');

Invalidate: Deletes a specific key value set.

await this.cacheProvider.invalidate('key:id=123');

InvalidatePrefix: Deletes all key value sets started by the passed key.

await this.cacheProvider.invalidatePrefix('key');

PreviousProvidersNextCrypto

Last updated 6 months ago

Was this helpful?