boxlang-caching

Configure multi-region BoxLang caching with TTL and eviction policies.

Updated Apr 10, 2026
One-click install
npx skills add https://github.com/ortus-boxlang/skills --skill boxlang-caching-ortus-boxlang
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: boxlang-caching
Source: https://github.com/ortus-boxlang/skills/tree/main/boxlang-developer/caching
Command: npx skills add https://github.com/ortus-boxlang/skills --skill boxlang-caching-ortus-boxlang

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

BoxLang caching configuration and usage are often repetitive and error-prone. This skill standardizes multi-region caching, TTL policies, eviction, and distributed locking to improve performance and consistency across applications.

Core Features & Use Cases

  • Centralized cache configuration in boxlang.json with multiple named regions (default, sessions, queries, files).
  • BIF-based operations: cachePut, cacheGet, cacheRemove, and cacheGetOrSet for efficient data access and invalidation.
  • Support for distributed caching via Redis and Couchbase modules, plus eviction policies and regional invalidation patterns for scalable apps.

Quick Start

Configure a default cache in boxlang.json and demonstrate a simple put/get sequence in your application.

Frequently Asked Questions about boxlang-caching

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure multi-region caching in BoxLang?

Configure multi-region caching in BoxLang by defining named cache regions like default, sessions, queries, and files within your boxlang.json file. This centralizes cache configuration to standardize TTL policies and eviction rules across your application.

What BoxLang functions are available for cache put and get operations?

BoxLang provides BIF-based operations for cache put and get operations, including cachePut, cacheGet, cacheRemove, and cacheGetOrSet. These functions enable efficient data access, regional invalidation, and distributed locking for your caching layer.

Can I use Redis or Couchbase for distributed caching in BoxLang?

Yes, BoxLang supports distributed caching with Redis and Couchbase modules. You can integrate these platforms to handle distributed locking, eviction policies, and regional invalidation patterns required for scalable application architectures.

How does cache invalidation and TTL work in BoxLang applications?

Cache invalidation and TTL in BoxLang applications work by applying standardized time-to-live policies and eviction rules to named cache regions. You can use cacheRemove and cacheGetOrSet to manually or automatically manage stale data.

What is the best way to standardize cache eviction policies across BoxLang apps?

The best way to standardize cache eviction policies across BoxLang apps is by centralizing your configuration in boxlang.json. Defining multiple named regions with specific TTL and eviction rules ensures consistent performance and behavior application-wide.