Use when caching DNS responses with TTL and prefetch.
Scanned 9/10/2026
Install to Claude Code
npx -y skills add LoopyLuci/Skills --skill dns-cache-layer --agent claude-codeInstalls into .claude/skills of the current project.
Are you the author of Dns Cache Layer?
Add the live security badge to your README — it updates automatically with every re-scan.
[](https://www.skillsdirectory.com/skills/loopyluci-dns-cache-layer)More formats (shields.io, HTML) on the badges page.
---
name: dns-cache-layer
title: DNS Cache Layer
description: Use when caching DNS responses with TTL and prefetch.
category: networking
tags: [dns, cache, performance, lru, concurrent, rust]
---
# DNS Cache Layer
**Trigger**: Use when implementing DNS response caching, prefetching, or negative caching.
## Key Libraries
- **Rust**: `lru`, `moka` (high-perf concurrent cache), `dashmap`, `scc`
- **Python**: `cachetools`, `aiocache`
## Implementation
1. Two-tier cache: L1 (hot, moka concurrent, ~10K) + L2 (warm, scc sharded, ~1M)
2. TTL-aware eviction with min/max bounds (clamp to configurable range)
3. Negative caching: cache NXDOMAIN with short TTL (60-300s) to reduce upstream load
4. Prefetch: predict popular domains via frequency tracking; refresh before TTL expiry
5. Serialization for persistence via `bincode` or `messagepack`
## Connected Skills
`dns-adblock-engine`, `encrypted-dns-resolver`, `realtime-dashboard`, `traffic-analyzer`
## Pitfalls
- Concurrent eviction + prefetch causes thundering herd — use `moka::try_get_with`
- Serialization must include expiry timestamps, not just TTL
Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.
No comments yet. Be the first to comment!
Ultra-compressed communication mode. Cuts token usage ~75% by speaking like caveman while keeping full technical accuracy. Supports intensity levels: lite, full (default), ultra, wenyan-lite, wenyan-full, wenyan-ultra. Use when user says "caveman mode", "talk like caveman", "use caveman", "less tokens", "be brief", or invokes /caveman. Also auto-triggers when token efficiency is requested.