Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

README.md

cache

version OpenSSF Scorecard mit size build

Caching layer for NodeSecure CLI and server, handling configuration, analysis payloads, and cache state management.

Requirements

Getting Started

This package is available in the Node Package Repository and can be easily installed with npm or yarn.

$ npm i @nodesecure/cache
# or
$ yarn add @nodesecure/cache

Features

  • Stores and retrieves configuration and analysis payloads.
  • Manages a Most Recently Used (MRU) and Least Recently Used (LRU) list for payloads.
  • Supports cache initialization, reset, and removal of old payloads.
  • Handles payloads for multiple packages, including local and remote analysis results.

Usage example

import { AppCache } from "@nodesecure/cache";

const cache = new AppCache();

await cache.initPayloadsList();
await cache.setRootPayload(payload);

API