advanced-cache-js

1.0.0 • Public • Published

advanced-cache-js

A high-performance caching solution with advanced features.

Features

  • Multi-layer caching (in-memory, distributed cache, persistent storage)
  • Cache invalidation strategies (time-based, event-based, manual)
  • Integration with various cache stores (Redis, Memcached)
  • Cache warm-up and prefetching capabilities
  • Detailed cache hit/miss statistics and monitoring

Installation

npm install advanced-cache

Configuration

Create a config.js file in the src directory to manage the settings.

Usage

const CacheManager = require('advanced-cache-js');

(async () => {
  const cacheManager = new CacheManager();

  await cacheManager.set('key1', 'value1');
  const value = await cacheManager.get('key1');
  console.log(value); // Output: value1

  const stats = await cacheManager.stats();
  console.log(stats);
})();

Testing

Run tests with Mocha and Chai:

npm test

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

License

This project is licensed under the MIT License.

Package Sidebar

Install

npm i advanced-cache-js

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

9.47 kB

Total Files

13

Last publish

Collaborators

  • hemant52