distributed-lock

Installation
SKILL.md

Distributed Locking

Prevent race conditions across multiple instances.

When to Use This Skill

  • Multiple instances processing the same job
  • Need to prevent duplicate operations
  • Singleton cron jobs across instances
  • Critical sections in distributed systems

Core Concepts

  1. Atomic acquisition - Only one holder at a time
  2. TTL expiration - Prevents deadlocks if holder crashes
  3. Lock extension - Renew for long-running operations
  4. Holder ID - Track who owns the lock

TypeScript Implementation

Related skills
Installs
24
GitHub Stars
780
First Seen
Jan 25, 2026