05-traffic-control-recommendations
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "05-traffic-control-recommendations":https://skillpi.com/zh/skills/deepskill-4be3492fba5c4b905cf97f140491621425557f75a92e22c70d6cc6ac25ee1b99。安装前核对上游来源和版本:https://github.com/planetscale/skills。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
制定一个用于 PlanetScale PostgreSQL 流量控制的安全推荐计划,包含预算和规则建议,但不实际施行这些规则。
介绍来源: third_party · planetscale · 1.0.0 参考来源
SkillPi 解读
- 能完成的任务
- 翻译待完成,请参阅来源文档。
- 适合谁
- 来源文档未说明。
- 输入和输出
- 翻译待完成,请参阅来源文档。
- 软件、账号及付费要求
- 来源文档未说明。
- 限制与区别
- 来源文档未说明。
- 实测状态
- 未测试
文件浏览
Frontmatter
name: planetscale-traffic-control-recommendations
description: Build a safe recommendation plan for PlanetScale Postgres Database Traffic Control budgets and rules without applying them.Database Traffic Control recommendations
Purpose
For PlanetScale Postgres, recommend Traffic Control budgets and rules that protect critical traffic from runaway queries, traffic spikes, batch jobs, agents, and third-party integrations. Do not create or change budgets without approval.
Preconditions
Run this skill only for PlanetScale Postgres.
Before recommending rules, inspect:
- Current budgets and rules.
- Insights query patterns.
- Current query tags.
- Application routes and jobs.
- Known critical paths.
- Known expensive non-critical paths.
- Active incidents or recent anomalies.
If query tags are missing, recommend tagging first unless a fingerprint-specific rule is clearly needed for an immediate known offender.
Candidate traffic slices
Look for:
- Exports.
- Reports.
- Search endpoints.
- Admin dashboards.
- Backfills.
- Workers and queues.
- Webhooks from third-party systems.
- BI tools.
- Agent-generated read queries.
- High-frequency polling.
- Known expensive query fingerprints.
- Customer-triggered endpoints with high variance.
Budget modes
Recommend in this order:
warnmode first for normal rollout.- Observe warnings and false positives.
- Tune tags, fingerprints, and thresholds.
- Move to
enforceonly with explicit approval and an emergency rollback path.
Do not recommend starting directly in enforce unless there is an active incident and the operator explicitly asks for emergency mitigation.
Rule strategy
Prefer tag-based rules when tags are stable and bounded:
source=agentsource=bifeature=exportfeature=reportroute=/admin/reportsjob=DailyBackfillservice=analytics-worker
Use fingerprint rules when:
- A specific known query pattern is dangerous.
- Tagging is missing or unreliable.
- The query source is hard to attribute.
Use a separate budget for each materially different traffic class.
Do not combine unrelated traffic in one budget because it hides who is consuming the budget.
Suggested default budgets
Use these as recommendation patterns, not as values to apply blindly.
Agent budget
Target: queries tagged source=agent or source=mcp.
Intent: prevent agents from starving application traffic.
Mode: start in warn.
Recommendation: agents should prefer replicas and read-only scopes. Writes require human approval.
Export/reporting budget
Target: feature=export, feature=report, or specific report route/job.
Intent: keep customer-triggered reporting from consuming all database resources.
Mode: start in warn; consider enforce after observation.
Background job budget
Target: worker service, queue, or job tags.
Intent: prevent backfills and retries from starving interactive traffic.
Mode: warn first; enforce only after confirming queue backpressure behavior.
Third-party integration budget
Target: source=integration, partner-specific bounded tags, or route templates for inbound integration calls.
Intent: isolate unpredictable partner behavior.
Mode: warn first.
Known fingerprint budget
Target: specific expensive query fingerprint.
Intent: contain a known pathological query while code or schema fixes are developed.
Mode: warn first unless emergency.
“Each tag value” strategy
When PlanetScale supports applying a budget separately for each unique value of a selected tag, recommend it for bounded tags such as:
applicationserviceroutewhen normalizedjobfeaturesource
Do not recommend it for unbounded tags such as user IDs, request IDs, raw tenant IDs, emails, UUIDs, or raw URLs.
Limits and caveats to include
Every recommendation must explain:
- Traffic Control limits resource use; it does not replace query tuning.
- It is not a web application firewall.
- It does not replace application-level rate limits.
- Limits are guardrails, not exact guarantees for every failure mode.
- Bad tags create bad rules.
- Enforce mode can reject queries and affect application behavior.
Output format
For each proposed budget:
- Budget name.
- Target branch.
- Mode: off, warn, or enforce.
- Matched traffic slice.
- Rule type: tag, fingerprint, keyspace, query kind.
- Proposed tags or fingerprint.
- Limit rationale.
- Queries seen in Insights that justify it.
- Safety risk.
- Test/observe plan.
- Rollback plan.
- Approval requirement.
End with:
“No Traffic Control budgets or rules have been created, updated, deleted, or enforced.”
当前收录版本
1.0.0
安全与评测信息
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- 为 PlanetScale Postgres 提供专业的数据库流量控制推荐方案
- 解决生产环境中 runaway queries 和流量突增等核心痛点
- 面向数据库运维人员的实用工具
亮点
- 触发词精准:PlanetScale、PostgreSQL、Traffic Control 等关键词明确
- 功能边界清晰:仅推荐不实际应用规则
- 适用场景描述完整
亮点
- 文档结构完整,包含 Purpose、Preconditions、策略说明等必要章节
- 提供多个具体预算推荐示例和输出格式规范
- 执行流程清晰,有明确的审批和回滚机制
亮点
- 安全策略完善:warn 模式优先,enforce 需审批
- 包含完整的风险说明和回滚计划
- 不实际应用规则,避免误操作风险
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
未从主文档识别到上述常见操作,不能据此判断无需权限或没有风险。
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
来源文档未说明。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。