link-loom/loom-sdk
51.4
Adequate · 8 November 2026
5.6k
lines of production code
JavaScript
primary language
7
measurements over time
What this system is
Link Loom SDK is a Node.js application backbone that manages the lifecycle and initialization of monoliths, microservices, and workers through a finite state machine. It provides a modular infrastructure for handling HTTP requests with SSE support, in-process worker threads with crash isolation, and dynamic event streaming via WebSocket and internal buses. The system standardizes external service integration for databases, storage, and email, while offering built-in utilities for security, data modeling, and observability.
Features
Initial release of Link Loom SDK with runtime orchestration and adapters
This entry introduces the Link Loom SDK, a Node.js runtime foundation that manages application initialization, dependency resolution, and lifecycle via a finite state machine. The SDK exposes core components including the Loom engine, BaseModel, Property, BaseWorker, and specific adapters for Workers and Streams through the main entry point. It also establishes development standards by adding ESLint and Prettier configurations and updates the project documentation to reflect its architecture as an application backbone for monoliths, microservices, and workers.
(repo-wide) · high confidence
Introduce in-process Worker runtime with lifecycle management and thread isolation
The system now includes a new \WorkersModule\ in \src/adapters/workers\ that manages the lifecycle of long-lived, in-process worker instances. This module introduces a deterministic finite state machine (FSM) to handle transitions between states such as INACTIVE, ACTIVE\_FOREGROUND, ACTIVE\_BACKGROUND, SUSPENDED, and CRASHED, ensuring robust lifecycle management. It also adds a \ThreadedWorkerProxy\ and \worker.thread.js\ to execute worker logic in separate Node.js worker threads, providing isolation and preventing crash masking. The module exposes a public API for registering, spawning, activating, deactivating, suspending, resuming, and stopping workers, along with utilities for alias management and performance monitoring.
src/adapters/workers · high confidence
Introduction of FunctionsModule for managing cache, timed, and startup functions
A new FunctionsModule has been added to the application's adapter layer to centralize the initialization and lifecycle management of background tasks. This module loads function definitions from the core 'src/functions' cluster and organizes them into three categories: cache, timed, and startup. It handles the dynamic instantiation of these functions, manages scheduled execution intervals for timed tasks using moment.js for time calculations, and ensures startup functions run either immediately or upon a server-loaded event via the event bus. The module also provides structured logging with a specific namespace and error handling to prevent initialization failures from crashing the application.
src/adapters/functions · high confidence
New StreamModule adapter for dynamic stream integration
The application now includes a new StreamModule adapter located at src/adapters/streams/stream.module.js, which enables the dynamic loading and instantiation of stream classes from the src/streams directory. This module is integrated into the main Loom SDK entry point (src/loom.sdk.js) via the \#setupAdapterModules method, allowing the engine to automatically discover, load, and manage stream instances during initialization while providing specific logging and error handling for each stream.
src · high confidence
New modular infrastructure components for database, email, observability, push, and storage
The infrastructure layer now includes dedicated module classes (DatabaseModule, EmailModule, ObservabilityModule, PushModule, StorageModule) that standardize how external services are initialized. Each module reads its configuration from the application's module settings, checks if it is enabled, and dynamically loads the specified default adapter (e.g., from \src/adapters/database/...\) to provide a unified client interface. This change introduces a consistent pattern for enabling, configuring, and accessing infrastructure services across the application.
src/infrastructure · high confidence
New utility modules for security, data modeling, and real-time streaming
The \src/utils\ directory has been populated with a comprehensive suite of new utility classes to support core application capabilities. Security is enhanced with \crypto.util.js\ (AES-256-GCM encryption/decryption and HMAC signing) and \encoder.util.js\ (Base64 and AES-CTR ciphering), while \validator.util.js\ introduces JWT and signed-data verification. Data handling is standardized via \models/base.model.js\ and \models/property.model.js\, which provide a structured way to define entity properties with default types and statuses, supported by \data-types/definition.types.js\. Real-time communication is enabled by \sse.util.js\, which creates Server-Sent Event streams with proper header flushing, and \event.util.js\ for WebSocket topic-based emission. Additional utilities include \performance.util.js\ for tracking CPU/memory metrics, \generator.util.js\ for IDs and JWTs, \search.util.js\ for object/array queries, \io.util.js\ for request/response formatting, \sanitizer.util.js\ for input cleaning, and \lang.utils.js\ for native prototype extensions.
src/utils · high confidence
Architecture
New modular event system architecture with broker, bus, consumer, and producer components
The event handling infrastructure in src/adapters/events has been restructured into four distinct modules: EventBrokerModule manages the WebSocket server setup, BusModule initializes an internal event emitter, EventConsumerModule handles incoming events by connecting to a broker and subscribing to topics, and EventProducerModule manages outgoing events by listening for consumer connections and executing event handlers. Each module follows a consistent pattern with dependency injection, configuration-based enable/disable logic, and structured logging using a specific namespace format.
src/adapters/events · high confidence
Behavioural changes
Core module architecture restructured with new utility and dependency management
The core application structure has been refactored into distinct modules (Console, DataTypes, Dependencies, Settings, Utilities) to improve organization and maintainability. This change introduces a centralized dependency injection system that automatically loads and exposes common libraries (such as Express, Socket.io, and Helmet) to the rest of the application. It also adds new utility modules for performance tracking and Server-Sent Events (SSE) support, while updating the server configuration to use the 'extended' query parser and enforce security headers via Helmet.
src/core · high confidence
HTTP adapter refactored into modular components with SSE and nested route support
The HTTP adapter has been restructured into distinct modules (API, Model, Service) to improve architecture and maintainability. The API module now supports Server-Sent Events (SSE) for streaming responses, allowing real-time data delivery to clients. It also introduces per-route body size limits and supports file uploads via middleware. Additionally, the routing system now handles multi-level (nested) domain paths, enabling more granular URL structures. Model and Service modules are now explicitly loaded and registered, ensuring proper initialization of data types and service instances.
src/adapters/http · high confidence
Introduce BaseWorker class with crash-resistant lifecycle logging
A new BaseWorker class has been added to src/utils/workers to serve as the foundation for Link Loom Workers. It defines a standard lifecycle (setup, activate, deactivate, suspend, resume, terminate, handleSignal) and integrates with a WorkerStateMachine. Crucially, it implements a \#safeLog mechanism that wraps all logging calls in try/catch blocks, ensuring that logging failures (such as circular reference serialization errors) do not crash the worker or mask the actual outcome of lifecycle hooks, thereby improving reliability and observability.
src/utils/workers · high confidence
Test coverage
Added tests for namespaced service fixture
Added a comprehensive test suite for the namespaced service fixture, verifying that the system correctly loads and isolates namespaces (alpha, beta), handles route authentication (token, public, misconfigured), manages namespace-specific services and database storage, and generates distinct OpenAPI documents per namespace.
test, test/fixtures/namespaced-service · high confidence
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 48 → 51 (+3.8)
- Rubric changed (rubric-2026.10.5 → rubric-2026.11.2) — scores are not directly comparable.
Lenses
- Code Health 56 → 56 (+0.0)
- Architecture 80 → 80 (+0.0)
- Maturity 50 → 77 (+27.3)
- Readiness 38 → 38 (+0.0)
- Security 52 → 56 (+4.6)
- Performance 100 → 100 (+0.0)
Resolved (9)
- Confusing overlap in lifecycle management verbs. spawn implies creation, start implies activation, but background and foreground also imply activation modes. It is unclear if spawn creates and starts, or just creates. start vs background/foreground suggests start might be a default mode, but the existence of explicit mode methods makes start redundant or confusingly named.
- Documentation: no installation or build instructions (docs/cli/reference.md)
- Documentation: no usage examples (docs/core/utilities.module.md)
- Duplicate method name with different semantic intent. ModelBase.setBaseProperties appears to configure internal state/defaults for a model, while Property.setBaseProperties likely configures a specific property instance. The name 'setBaseProperties' is ambiguous in both contexts and suggests a shared implementation or intent that doesn't exist.
- Inconsistent retrieval patterns. There are separate methods for getting by alias, by pid, and by name+alias. This suggests a lack of a unified lookup mechanism. getByNameAndAlias is particularly confusing as it requires both, whereas others require only one.
- Medium CVE: [GHSA redacted] (package-lock.json)
- Redundant operation signatures. Similar to call, status and statusByPid duplicate the intent of retrieving worker status based on different identifier types.
- Redundant operation signatures. call and callByPid perform the same action (invoking a method on a worker) but accept different identifiers (name/alias vs pid). This forces users to know which identifier they have and choose the correct method, rather than having a single call method that accepts a flexible identifier or a worker reference.
- Redundant operation signatures. stop and stopByPid duplicate the intent of stopping a worker based on different identifier types.
New (4)
- High CVE: [GHSA redacted] (package-lock.json)
- doc comments repeat the names (src/adapters/workers/worker.state-machine.js)
- redundant comment (src/adapters/http/api.module.js)
- redundant comment (src/utils/validator.util.js)
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
link-loom/loom-sdk was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 8 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 4f7c6826f2c35539b72a0bdfa18b2548e0670d7b — the exact code this score is about.
- Scored under rubric-2026.11.2 — the same rubric and the same method as every other entry in this index.
- Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.3+preprod-bb0cb800cd0f.