What problem does it solve?
It prevents AIM’s process-internal shared Go packages from drifting into service-level coupling, so developers can reuse cross-cutting types and helpers safely without creating reverse dependencies.
Core Features & Use Cases
- Defines shared package scope: documents how
app/shared is meant to be used by app/auth, app/core, app/gateway, app/logic, and client modules, while explicitly forbidding reverse dependencies from business services.
- Captures cross-cutting capability boundaries: enumerates the key shared domains like
errorx, rpc, nacos, jwt, events, attachment, s3signer, and tracing, and the rules for how they should interact (e.g., tracing propagation in Kafka payloads).
- Improves consistency of infrastructure integration: sets expectations for gRPC/Nacos resolver scheme usage, Kafka span/trace injection patterns, and unified error handling across module boundaries.
Use case: when implementing attachment upload/parse or Kafka-driven event flows across multiple services, you can follow these shared-package rules to keep event DTOs, schema/validation, and tracing utilities consistent and correctly wired.
Quick Start
Ask the AI to summarize the allowed and forbidden dependencies for app/shared and extract the exact rules you must follow when adding a new shared package like app/shared/cache.