microservice-infrastructure_skill

This skill helps you implement microservice infrastructure foundations including conditional config, event-driven architecture, inter-service communication,
  • 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 microservice-infrastructure

  • SKILL.md11.0 KB

Overview

This skill documents core microservice infrastructure patterns used in a Kotlin-based CI platform. It focuses on conditional configuration, event-driven design, inter-service communication, and internationalization plus logging. The guidance is practical, framework-aligned (Spring Boot / Spring Cloud) and aimed at making distributed services robust and maintainable.

How this skill works

The content inspects configuration strategies (profiles, conditional beans, feature toggles), event dispatch and subscription patterns using message queues, and Feign-based service calls with discovery and circuit breakers. It also prescribes internationalization message files, SLF4J logging conventions, and sensitive-data masking. Each topic includes conventions, typical problems, and concrete implementation pointers for Kotlin/Spring ecosystems.

When to use it

  • When you need separate environment configs and runtime feature toggles
  • When components must be decoupled using asynchronous events or MQs
  • When services call each other and require discovery, timeouts, and fallback strategies
  • When user-facing text must support multiple locales
  • When you must standardize logs and mask sensitive data for compliance and observability

Best practices

  • Use @Profile and environment-specific application-{profile}.yml for environment isolation
  • Apply @ConditionalOnProperty for feature toggles and keep secrets encrypted
  • Design events implementing an IEvent interface and keep listeners idempotent
  • Define Feign clients in api-* modules, set sensible timeouts (connect 5s, read 30s) and add circuit breakers
  • Internationalize all user-visible strings and maintain messages_*.properties under support-files/i18n
  • Use SLF4J for logs, adhere to log levels, and mask passwords/tokens before logging

Example use cases

  • Switch configs between dev/test/prod using Spring profiles and conditional beans
  • Publish domain events to a durable MQ and process them asynchronously with retry and DLQ handling
  • Call downstream services with Feign, apply service discovery and implement graceful fallbacks
  • Add a new locale by creating messages_{locale}.properties and validating translations
  • Standardize logs across services and implement token/password masking before emitting logs

FAQ

Create application-{profile}.yml and start with --spring.profiles.active or annotate beans with @Profile to load environment-specific beans.

How can I ensure events are not lost?

Use a persistent MQ, enable retries on consumption, route final failures to a dead-letter queue, and monitor DLQs with alerts.

What if a Feign call times out?

Set reasonable connect/read timeouts, implement circuit breakers and fallback handlers, and make retries only for idempotent operations.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational