SShortSingh.
Back to feed

Distributed Locks Can Expire Correctly and Still Corrupt Data Without Fencing Tokens

0
·1 views

A distributed lock expiring on schedule does not prevent data corruption if a paused worker resumes and overwrites a newer update after its lease has already been claimed by another process. This is because distributed locks are effectively leases — they communicate ownership for a time window but cannot cancel in-flight writes or recall delayed network packets. A real-world parallel is the 2012 GitHub outage, where a ~90-second network disruption caused multiple file-server pairs to simultaneously believe they were the active owner of the same resource, requiring over five hours of recovery. The reliable fix is a fencing token: a strictly increasing integer issued by the lock coordinator on each acquisition, which the protected resource uses to reject any write carrying an older generation number. Unlike a random UUID — which only prevents an expired holder from releasing another's lock — a fencing token enforced at the storage layer ensures stale writes are rejected regardless of network or process delays.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

US Neural builds sub-10ms local semantic tool registry to replace LangChain routing

Engineers at US Neural have developed an open-source tool called Mycelium, designed to replace LangChain's built-in tool routing for AI agents. The team argues that LangChain's AgentExecutor becomes slow and unwieldy when managing 50 or more tools, resulting in brittle logic and high latency. Mycelium achieves a cold tool-discovery latency of 9.6ms, compared to 194ms reported for BM25-based approaches. The project reframes tool discovery as a distributed networking problem rather than a task delegated to a large language model. The code and benchmarking scripts have been published publicly on GitHub for independent review.

0
ProgrammingDEV Community ·

Developer Builds AI App to Identify Buildable Sets from Existing LEGO Collections

A solo developer has created Brickbeam, an AI-powered app designed to help families discover what they can build using LEGO bricks they already own. The idea emerged from a personal frustration: the developer's children would rummage through a large mixed collection and conclude they lacked the right pieces, prompting requests for new sets. Users photograph their LEGO bricks, and the app's AI analyzes the pieces to suggest possible builds from the existing collection. Developing the tool proved technically challenging, as recognizing overlapping, varied, and poorly lit pieces in a jumbled pile is a difficult computer vision problem. Future versions aim to let AI generate entirely new, physically buildable designs tailored to a user's specific brick inventory.

0
ProgrammingDEV Community ·

Developers fix hidden barriers blocking SigNoz's built-in LLM observability feature

During a hackathon held July 20–26, 2026, a team discovered that SigNoz v0.133.0 already ships a complete LLM observability product in its open-source codebase, but several silent defaults prevent self-hosters from ever seeing it work. Two feature flags — enable_ai_observability and use_dashboard_v2 — are disabled by default, causing the UI to silently redirect or render blank dashboards even when the backend returns a success response. Additionally, two data registries that power model pricing and vendor span-mapping ship with zero rows, meaning dashboards display nothing out of the box. The team also identified a documentation mismatch where SigNoz's own CrewAI guide directs users to an instrumentation library that emits no compatible telemetry attributes. Their fix, enabling both flags together and seeding the empty registries, was upstreamed, and they also added answer-quality measurement as a previously missing observability signal.

0
ProgrammingDEV Community ·

Openship Runs Its Control Plane Off-Server to Free Up VPS Resources

Openship, a new open-source self-hosted PaaS tool, launched in July 2026 and quickly gained several thousand GitHub stars within a week. Unlike competitors such as Coolify, Dokploy, and CapRover, Openship separates its control plane from the production server, running builds locally and deploying finished container images over SSH. This means the production server only runs containers, freeing it from resource-heavy build processes that can destabilize live apps on low-spec machines like a 4 GB VPS. The tool bundles a broad feature set including CI/CD pipelines, database support, SSL automation, edge caching, and an unusual built-in SMTP server with DKIM, SPF, and DMARC configuration. The main tradeoff is that running the control plane on a laptop means the dashboard is offline when the machine is, limiting team access and webhook reliability unless a dedicated server is used instead.

Distributed Locks Can Expire Correctly and Still Corrupt Data Without Fencing Tokens · ShortSingh