- Home
- Skills
- Tencentblueking
- Bk Ci
- Pipeline Template Module
pipeline-template-module_skill
- Kotlin
2.5k
GitHub Stars
1
Bundled Files
2 months ago
Catalog Refreshed
4 months ago
First Indexed
Readme & install
Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.
Installation
Preview and clipboard use veilstrat where the catalogue uses aiagentskills.
npx veilstrat add skill tencentblueking/bk-ci --skill pipeline-template-module- SKILL.md63.7 KB
Overview
This skill documents the pipeline-template-module architecture for reusable pipeline templates in a CI/CD platform. It explains template creation, versioning, instantiation, permission control, and integration with a developer marketplace. The guide helps engineers design, extend, and operate template features in Kotlin-based microservices.
How this skill works
The module exposes V1 and V2 REST APIs, POJO models, service facades, version managers and DAOs to persist template info, resource versions and instantiation records. V2 adds drafts, branch/version handlers, post-processors and migration utilities for safer evolution. RBAC-based permission services and store integration enable controlled sharing and cross-project installation.
When to use it
- You need reusable pipeline configurations to enforce standards across projects.
- You must implement template versioning, draft/publish workflows or rollback capabilities.
- You want bulk instantiation or batch updates of pipelines from a single template.
- You are integrating templates into a developer marketplace or cross-project access layer.
- You require RBAC-controlled template operations and audit-friendly version history.
Best practices
- Prefer V2 architecture for new features: supports drafts, clearer version lifecycle and migration helpers.
- Model template resources separately from template metadata: keep T_PIPELINE_TEMPLATE_RESOURCE_VERSION for versioned content and T_PIPELINE_TEMPLATE_INFO for metadata.
- Use facade services to centralize business rules and keep controllers thin; split responsibilities into persistence, versioning and instance services.
- Implement event-driven listeners for async post-processing (install hooks, compatibility checks, audit logs).
- Enforce permission checks at API boundaries and use abstract permission service to support RBAC and test mocks.
Example use cases
- Create a shared build-and-deploy template and publish it to the developer store for consumption across teams.
- Maintain template release channels: create draft, run validation, publish a release, and roll back to a prior version if needed.
- Batch instantiate a template across multiple projects to onboard new microservices with consistent CI/CD pipelines.
- Migrate legacy V1 templates to V2 using migration services and version managers while preserving history and instances.
- Implement a permissioned marketplace flow where only authorized operators can publish system or public templates.
FAQ
Choose V2 for new development—V2 supports drafts, richer version management and migration tools; keep V1 only for compatibility with legacy consumers.
How are template instances tracked?
Instances are recorded in instance base and item tables with status, counts and parameters so bulk operations and progress can be monitored and audited.