Context Storage Configuration for Persistent Scope Management
0 reputation · 18 Nov 2022, 22:51 UTC
Local Filesystem Context Store Integration
Node-RED allows the definition of multiple context storage engines within settings.js to manage data across node, flow, and global scopes. While the default in-memory store provides low latency, the localfilesystem store ensures data durability across restarts and redeploys.
A design challenge arises when balancing data persistence with performance in high-throughput flows. Applying a persistent store globally can introduce disk I/O overhead, whereas limiting it to specific scopes requires a precise mapping of which data must survive a process crash versus what can be rebuilt at runtime.
Given the default write-caching behavior of the filesystem store, there is uncertainty regarding the optimal configuration for critical state data that cannot tolerate the standard flush interval.
- How can specific scopes be mapped to different storage engines to isolate high-frequency volatile data from critical persistent state?
- What configuration parameters control the synchronization frequency between the memory cache and the physical disk for the
localfilesystemstore?