Skip to content

12 — SpringBoot与Web开发索引

定位: SpringBoot 自动配置 + 注解驱动 — Java 后端开发的行业标准 面试高频度: ⭐⭐⭐⭐⭐

一、知识全景图

┌─────────────────────────────────────────────────────────────┐
│              SpringBoot 核心全景                             │
│                                                              │
│  ┌─────────── 自动配置 ────────────────────────────┐        │
│  │  @SpringBootApplication = @Config + @EnableAuto + @Scan │
│  │  spring.factories → 条件装配 (@ConditionalOn*)          │
│  └──────────────────────────────────────────────────┘        │
│                                                              │
│  ┌─────────── 分层架构 ────────────────────────────┐        │
│  │  @Controller   → 接收请求                        │        │
│  │  @Service      → 业务逻辑                        │        │
│  │  @Repository   → 数据访问                        │        │
│  │  @Configuration → Bean 定义                      │        │
│  └──────────────────────────────────────────────────┘        │
│                                                              │
│  ┌─────────── Web 层 ──────────────────────────────┐        │
│  │  DispatcherServlet → HandlerMapping → Handler   │        │
│  │  @RequestParam / @PathVariable / @RequestBody    │        │
│  │  @RestControllerAdvice → 全局异常处理             │        │
│  └──────────────────────────────────────────────────┘        │
│                                                              │
│  ┌─────────── 数据访问 ────────────────────────────┐        │
│  │  @Transactional → 事务传播 + 隔离级别             │        │
│  │  Spring Data + MyBatis 整合                     │        │
│  └──────────────────────────────────────────────────┘        │
└─────────────────────────────────────────────────────────────┘

二、子专题导航

#主题面试频率核心内容
**注解体系速查**注解体系速查⭐⭐⭐⭐⭐按层分类的注解全景、@SpringBootApplication 拆解
**Web层开发**Web层开发⭐⭐⭐⭐RestController、参数绑定、统一异常处理
**数据访问与事务**数据访问与事务⭐⭐⭐⭐@Transactional 原理、传播行为、隔离级别

📚 相关文件

  • **MyBatis索引** — MyBatis-Spring 整合
  • **SpringBoot测试** — SpringBoot Test
  • **注解体系** — 注解底层机制
  • **Java文库设计文档** — 返回总纲

Knowledge4J — Java 知识库