{
  "schemaVersion": "1.0",
  "item": {
    "slug": "db",
    "name": "Database",
    "source": "tencent",
    "type": "skill",
    "category": "数据分析",
    "sourceUrl": "https://clawhub.ai/ivangdavila/db",
    "canonicalUrl": "https://clawhub.ai/ivangdavila/db",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/db",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=db",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "slug": "db",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-01T10:09:32.474Z",
      "expiresAt": "2026-05-08T10:09:32.474Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=db",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=db",
        "contentDisposition": "attachment; filename=\"db-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "db"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/db"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/db",
    "agentPageUrl": "https://openagent3.xyz/skills/db/agent",
    "manifestUrl": "https://openagent3.xyz/skills/db/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/db/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Connection Traps",
        "body": "Connection pools exhausted = app hangs silently — set max connections, monitor pool usage\nEach Lambda/serverless invocation may open new connection — use connection pooling proxy (RDS Proxy, PgBouncer)\nConnections left open block schema changes — ALTER TABLE waits for all transactions\nIdle connections consume memory — set connection timeout, kill idle connections"
      },
      {
        "title": "Transaction Gotchas",
        "body": "Long transactions hold locks and bloat MVCC — keep transactions short\nRead-only transactions still take snapshots — can block vacuum/cleanup in Postgres\nImplicit autocommit varies by database — explicit BEGIN/COMMIT is safer\nDeadlocks from inconsistent lock ordering — always lock tables/rows in same order\nLost updates from read-modify-write without locking — use SELECT FOR UPDATE or optimistic locking"
      },
      {
        "title": "Schema Changes",
        "body": "Adding column with default rewrites entire table in old MySQL/Postgres — use NULL default, backfill, then alter\nIndex creation locks writes in some databases — use CONCURRENTLY in Postgres, ONLINE in MySQL 8+\nRenaming column breaks running application — add new column, migrate, drop old\nDropping column with active queries causes errors — deploy code change first, then schema change\nForeign key checks slow bulk inserts — disable constraints, insert, re-enable"
      },
      {
        "title": "Backup and Recovery",
        "body": "Logical backups (pg_dump, mysqldump) lock tables or miss concurrent writes — use consistent snapshot\nPoint-in-time recovery requires WAL/binlog retention — configure before you need it\nBackup verification: restore regularly — backups that can't restore aren't backups\nReplication lag during backup can cause inconsistency — backup from replica, verify consistency"
      },
      {
        "title": "Replication Traps",
        "body": "Replication lag means stale reads — check lag before trusting replica data\nWrites to replica corrupt replication — make replicas read-only\nSchema changes can break replication — replicate schema changes, don't apply separately\nSplit-brain after failover loses writes — use fencing/STONITH to prevent\nPromoting replica doesn't redirect connections — application must reconnect to new primary"
      },
      {
        "title": "Query Patterns",
        "body": "N+1 queries from ORM lazy loading — eager load relationships or batch queries\nMissing indexes on foreign keys slows joins and cascading deletes\nLarge IN clauses become slow — batch into multiple queries or use temp table\nCOUNT(*) on large tables is slow — use approximate counts or cache\nSELECT without LIMIT on unbounded data risks OOM"
      },
      {
        "title": "Data Integrity",
        "body": "Application-level unique checks have race conditions — use database constraints\nCheck constraints often disabled for \"flexibility\" then data corrupts — keep them on\nOrphan rows from missing foreign keys — add constraints retroactively, clean up first\nTimezone confusion: store UTC, convert on display — never store local time without zone\nFloating point for money causes rounding errors — use DECIMAL or integer cents"
      },
      {
        "title": "Scaling Limits",
        "body": "Single table over 100M rows needs sharding strategy — plan before you hit it\nAutovacuum falling behind causes table bloat — monitor dead tuple ratio\nQuery planner statistics stale after bulk changes — ANALYZE after large imports\nConnection count doesn't scale linearly — more connections = more lock contention\nDisk IOPS often bottleneck before CPU — monitor I/O wait"
      }
    ],
    "body": "Database Gotchas\nConnection Traps\nConnection pools exhausted = app hangs silently — set max connections, monitor pool usage\nEach Lambda/serverless invocation may open new connection — use connection pooling proxy (RDS Proxy, PgBouncer)\nConnections left open block schema changes — ALTER TABLE waits for all transactions\nIdle connections consume memory — set connection timeout, kill idle connections\nTransaction Gotchas\nLong transactions hold locks and bloat MVCC — keep transactions short\nRead-only transactions still take snapshots — can block vacuum/cleanup in Postgres\nImplicit autocommit varies by database — explicit BEGIN/COMMIT is safer\nDeadlocks from inconsistent lock ordering — always lock tables/rows in same order\nLost updates from read-modify-write without locking — use SELECT FOR UPDATE or optimistic locking\nSchema Changes\nAdding column with default rewrites entire table in old MySQL/Postgres — use NULL default, backfill, then alter\nIndex creation locks writes in some databases — use CONCURRENTLY in Postgres, ONLINE in MySQL 8+\nRenaming column breaks running application — add new column, migrate, drop old\nDropping column with active queries causes errors — deploy code change first, then schema change\nForeign key checks slow bulk inserts — disable constraints, insert, re-enable\nBackup and Recovery\nLogical backups (pg_dump, mysqldump) lock tables or miss concurrent writes — use consistent snapshot\nPoint-in-time recovery requires WAL/binlog retention — configure before you need it\nBackup verification: restore regularly — backups that can't restore aren't backups\nReplication lag during backup can cause inconsistency — backup from replica, verify consistency\nReplication Traps\nReplication lag means stale reads — check lag before trusting replica data\nWrites to replica corrupt replication — make replicas read-only\nSchema changes can break replication — replicate schema changes, don't apply separately\nSplit-brain after failover loses writes — use fencing/STONITH to prevent\nPromoting replica doesn't redirect connections — application must reconnect to new primary\nQuery Patterns\nN+1 queries from ORM lazy loading — eager load relationships or batch queries\nMissing indexes on foreign keys slows joins and cascading deletes\nLarge IN clauses become slow — batch into multiple queries or use temp table\nCOUNT(*) on large tables is slow — use approximate counts or cache\nSELECT without LIMIT on unbounded data risks OOM\nData Integrity\nApplication-level unique checks have race conditions — use database constraints\nCheck constraints often disabled for \"flexibility\" then data corrupts — keep them on\nOrphan rows from missing foreign keys — add constraints retroactively, clean up first\nTimezone confusion: store UTC, convert on display — never store local time without zone\nFloating point for money causes rounding errors — use DECIMAL or integer cents\nScaling Limits\nSingle table over 100M rows needs sharding strategy — plan before you hit it\nAutovacuum falling behind causes table bloat — monitor dead tuple ratio\nQuery planner statistics stale after bulk changes — ANALYZE after large imports\nConnection count doesn't scale linearly — more connections = more lock contention\nDisk IOPS often bottleneck before CPU — monitor I/O wait"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/ivangdavila/db",
    "publisherUrl": "https://clawhub.ai/ivangdavila/db",
    "owner": "ivangdavila",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/db",
    "downloadUrl": "https://openagent3.xyz/downloads/db",
    "agentUrl": "https://openagent3.xyz/skills/db/agent",
    "manifestUrl": "https://openagent3.xyz/skills/db/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/db/agent.md"
  }
}