database-design

Design BK-CI database schemas with naming, indexing, and partitioning guidelines.

2.5k|521|Updated May 29, 2019
One-click install
npx skills add https://github.com/TencentBlueKing/bk-ci --skill database-design-tencentblueking
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-design
Source: https://github.com/TencentBlueKing/bk-ci/tree/main/ai/skills/database-design
Command: npx skills add https://github.com/TencentBlueKing/bk-ci --skill database-design-tencentblueking

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

BK-CI数据库设计规范与表结构指南,覆盖命名规范、字段类型选择、索引设计、分表策略、数据归档。当用户设计数据库表、优化索引、规划分表策略或进行数据库架构设计时使用。

Core Features & Use Cases

  • 数据库命名规范与字段类型选型的一致性
  • 索引设计、分表/分区策略与归档方案的指导
  • 面向多服务的数据库架构设计与规范化示例
  • Use Case: 为新服务设计 T_PROJECT/ T_PIPELINE_INFO 等核心表时遵循标准
  • Use Case: 审核现有数据库模式以提升可维护性与扩展性

Quick Start

Review BK-CI’s database design guidelines and apply them when drafting a new service schema.

Frequently Asked Questions about database-design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I design database schemas for new BK-CI services?

Design database schemas for BK-CI services by following standard naming conventions, selecting appropriate field data types, and applying indexing guidelines. The skill enforces standard DDL practices to ensure consistency and scalability across modules.

What are the standard naming conventions for BK-CI database tables?

Standard naming conventions for BK-CI database tables require structured prefixes like T_PROJECT or T_PIPELINE_INFO for core entities. These rules ensure schema consistency and maintainability across multiple services within the platform.

How do I review an existing database schema for consistency?

Review existing database schemas for consistency by checking field type selection, indexing strategies, and partitioning rules against BK-CI standards. This process identifies deviations to improve schema maintainability and scalability.

How do I plan database partitioning and data archival strategies?

Plan database partitioning and data archival strategies by applying BK-CI guidelines for sharding tables and archiving historical records. This approach manages data growth effectively across various service modules.

How do I write idempotent database migration scripts?

Write idempotent database migration scripts by following BK-CI standard DDL practices and script organization guidelines. This ensures migrations can be re-run safely without causing schema conflicts or data duplication.

Related Skills