# email-ec-boot **Repository Path**: coding_13/email-ec-boot ## Basic Information - **Project Name**: email-ec-boot - **Description**: 发送谷歌邮箱 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-11-06 - **Last Updated**: 2025-11-06 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Email Service System ## Project Overview This project is an email service system built on Spring Boot, designed to handle email sending requests. The system features a clear structure and well-modularized design, making it easy to maintain and extend. ## Key Features - Provides REST API endpoints for sending emails - Supports unified response formats - Integrates logging and exception handling - Supports MDC context tracking for enhanced log traceability ## Technology Stack - Spring Boot - Spring AOP - SLF4J - Jackson for JSON processing - Maven ## Module Overview - `email-front-boot`: Main application module containing the startup class and controllers - `email-common-core`: Core utilities and common components - `email-web-common`: Web-related common components, including global exception handler - `email-dto`: Data Transfer Object module - `email-service`: Email service interfaces and implementations - `email-constant`: Constant definitions - `email-enums`: Enum definitions ## Core Features ### Unified Response Format The `ResponseDTO` class is used as the return model for all APIs to ensure consistent response formatting. ### Logging AOP-based logging is implemented via the `LoggingAspect` class to automatically record method invocation details before and after controller methods are executed. ### Exception Handling The global exception handler `ControllerErrorAdvice` uniformly processes various exceptions and returns standardized error responses. ### MDC Tracing Supports request chain tracing through `WebTraceFilter` and `MDCTraceUtil` to manage request context trace IDs and span IDs. ## API Documentation ### Send Email **URL:** `/v1/email/send` **Method:** POST **Request Body:** `EmailSendDTO` object containing all required information for email sending **Response:** `ResponseDTO` object indicating the result of the request processing ## Configuration Files - `application.yml`: Main configuration file - `application-dev.yml`: Development environment configuration - `application-test.yml`: Testing environment configuration - `logback.xml`: Logging configuration ## How to Run 1. Ensure Java 8+ and Maven are installed 2. Run the command: `mvn spring-boot:run` ## Dependency Management Dependencies are managed via Maven, with specific dependencies defined in each module’s `pom.xml` file. ## Logging The system uses SLF4J as the logging facade with Logback as the underlying implementation, configured via `logback.xml`. ## License This project is licensed under the Apache 2.0 License. Refer to the license notice in the project files for details.