Skip to content
DevOps AI ToolKit
Newsletter
All prompts
AI for OpenStack Difficulty: Advanced ClaudeChatGPTCursor

Swift Object Expiration & Versioning Design Prompt

Design a Swift object lifecycle strategy combining object versioning and the object-expirer so tenants get recoverable overwrites and automatic deletion, without the expirer queue backing up or versioning silently doubling storage cost.

Target user
Swift operators designing object lifecycle policies
Difficulty
Advanced
Tools
Claude, ChatGPT, Cursor

The prompt

You are a senior Swift architect who has run large multi-region clusters with lifecycle policies and understands the expirer and versioning internals.

I will provide:
- Cluster layout: proxy/storage nodes, storage policies (replication vs EC), regions/zones
- Workload: object size distribution, overwrite/delete rate, container object counts
- Requirements: retention/recovery needs, compliance deletion deadlines, cost constraints
- Current config: whether `object-expirer` runs, `[filter:versioned_writes]` enabled, `allow_object_versioning`, expirer concurrency/interval

Your job:

1. **Choose the right versioning mode** — legacy `X-Versions-Location` vs the newer object versioning (`X-Versions-Enabled`) — and explain the container-layout, listing, and DELETE-semantics differences, plus which suits the stated recovery requirement.

2. **Capacity modeling** — estimate the storage and object-count multiplier from versioning given the overwrite rate, and its effect on container databases (large container DBs slow listings and replication). Recommend container sharding thresholds if needed.

3. **Expiration design** — set `X-Delete-At`/`X-Delete-After` strategy, size the `object-expirer` (concurrency, processes, interval) against the projected expiry-queue rate, and prevent the expirer from falling permanently behind.

4. **Interaction hazards** — how versioning and expiration interact (expiring current vs versioned objects), and the ordering that avoids orphaned versions or premature deletion of the only recoverable copy.

5. **Monitoring** — expirer queue depth/lag, versioned-container growth, and per-policy byte/object accounting to catch runaway cost.

Output as: (a) versioning-mode recommendation with the semantics tradeoff, (b) a capacity/object-count model with the multiplier math, (c) expirer sizing config values tied to the expiry rate, (d) the versioning+expiration interaction rules and safe ordering, (e) monitoring metrics and thresholds. Include the exact container headers and config-file stanzas for each recommendation.

Always model the storage-cost and container-DB impact before recommending versioning be turned on.

Run this prompt with AI

Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.

Related prompts

More OpenStack prompts & error guides

Browse every OpenStack prompt and troubleshooting guide in one place.

Free download · 368-page PDF

Reading prompts? Get all 500 in one free PDF

500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.

  • 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
  • Instant PDF download — yours free, forever
  • Plus one practical AI-workflow email a week (no spam)

Single opt-in · unsubscribe anytime · no spam.