Contents
see List작성일 2026. 04. 11.
Spring Boot 3.4 주요 변경사항
Spring Boot 3.4는 SSL 인증서 모니터링, Graceful Shutdown 기본 활성화, Actuator 엔드포인트 확장성 개선 등 운영 환경에 중요한 기능들이 추가되었습니다.
SSL 인증서 모니터링
프로덕션 환경에서 SSL 인증서 만료는 심각한 장애를 유발합니다. Spring Boot 3.4는 인증서 상태를 자동으로 모니터링합니다.
설정 방법
# application.yml
server:
ssl:
key-store: classpath:keystore.p12
key-store-password: ${SSL_PASSWORD}
key-store-type: PKCS12
management:
endpoints:
web:
exposure:
include: health,info
endpoint:
health:
show-details: always
health:
ssl:
enabled: true
# 만료 30일 전부터 경고
certificate-validity-warning-threshold: 30dActuator /info 엔드포인트에서 SSL 정보 확인
// GET /actuator/info 응답 예시
{
"ssl": {
"bundles": {
"server": {
"certificateChain": [{
"subject": "CN=example.com",
"issuer": "CN=Let's Encrypt Authority",
"serialNumber": "03:a1:...",
"validityStarts": "2026-01-15T00:00:00Z",
"validityEnds": "2026-07-15T00:00:00Z",
"status": "VALID"
}]
}
}
}
}Health Check 연동
// GET /actuator/health 응답 (인증서 만료 임박 시)
{
"status": "OUT_OF_SERVICE",
"components": {
"ssl": {
"status": "OUT_OF_SERVICE",
"details": {
"server": {
"status": "OUT_OF_SERVICE",
"details": {
"expiresIn": "15 days",
"validUntil": "2026-04-26T00:00:00Z"
}
}
}
}
}
}Graceful Shutdown 기본 활성화
Spring Boot 3.4부터 Graceful Shutdown이 기본으로 활성화됩니다. 서버 종료 시 진행 중인 요청을 완료한 뒤 종료합니다.
# application.yml - 기본값이 graceful로 변경됨
server:
shutdown: graceful # 기본값 (이전 버전은 immediate)
spring:
lifecycle:
timeout-per-shutdown-phase: 30s # 대기 시간 (기본 30초)Graceful Shutdown 동작 확인 코드
@RestController
public class SlowController {
@GetMapping("/slow")
public String slow() throws InterruptedException {
// 10초 걸리는 작업 시뮬레이션
Thread.sleep(10000);
return "완료";
}
}
// SIGTERM 수신 시:
// 1. 새 요청 수신 중단
// 2. 진행 중인 /slow 요청 완료 대기 (최대 30초)
// 3. 모든 요청 완료 후 서버 종료Actuator 엔드포인트 확장
EndpointExposureOutcomeContributor 인터페이스로 커스텀 엔드포인트 노출 조건을 정의할 수 있습니다.
@Component
public class InternalOnlyEndpointContributor
implements EndpointExposureOutcomeContributor {
@Override
public EndpointExposureOutcome getExposureOutcome(
String endpointId,
EndpointExposure exposure) {
// 특정 엔드포인트는 내부 네트워크에서만 노출
if ("env".equals(endpointId) || "configprops".equals(endpointId)) {
if (exposure == EndpointExposure.WEB) {
return EndpointExposureOutcome.DISALLOWED;
}
}
return EndpointExposureOutcome.NEUTRAL;
}
}핵심 정리
- SSL 인증서 자동 모니터링으로 만료 사전 감지
- Graceful Shutdown이 기본 활성화되어 무중단 배포 안정성 향상
- Actuator 확장 인터페이스로 엔드포인트 노출 세밀 제어
- Liquibase Customizer, JCache 속성 커스터마이징 지원
spring
| No | 작성일 | Title |
|---|---|---|
| 2935 | 2026. 06. 02. | Spring Boot Redis 캐시 운영 가이드: TTL, 무효화, 캐시 스탬피드 방지 설계 |
| 2881 | 2026. 05. 25. | Spring API 오류 응답 표준화: ProblemDetail과 @RestControllerAdvice 실전 가이드 |
| 2813 | 2026. 05. 17. | Spring Boot 무중단 배포를 위한 Readiness·Liveness·Graceful Shutdown 실전 가이드 |
| 2611 | 2026. 04. 25. | Spring Security 7 Passkey(패스키) 완전 가이드: WebAuthn 기반 비밀번호 없는 인증 구현 |
| 2526 | 2026. 04. 17. | Spring Boot 3.4/3.5 + Spring Framework 7 핵심 신기능 실전 가이드: 구조적 로깅·Virtual Threads·API 버전닝 |
| 2492 | 2026. 04. 14. | Spring Boot 3.4 완벽 가이드: RestClient, OAuth2 개선, Virtual Threads 통합 |
| 2471 | 2026. 04. 13. | Spring Boot 3.5 핵심 기능 완벽 가이드: Structured Logging, Virtual Threads, SSL 설정 |
| 2451 | 2026. 04. 12. | Spring Boot 3.4 + Spring AI 실전 가이드: Virtual Threads와 MCP 통합 |
| 2427 | 2026. 04. 11. | Spring Boot 3.4 SSL 인증서 모니터링과 Graceful Shutdown 설정 가이드 |
| 2391 | 2026. 04. 09. | Spring Boot 3.5 실전 가이드 - 구조화 로깅, SSL 자동 설정, GraalVM 최적화 |