최근 포스트

[Spring Cloud Gateway] Logging Filter

1 분 소요

이 전에 살펴본 Global Filter를 로깅 출력에 적용해보자. 코드 apigateway-service filter/LoggingFilter.java 이 전에 만든 GlobalFilter와 같은 위치에 LoggingFilter를 생성한다. ```java @Component @S...

[Spring Cloud Gateway] Global Filter

1 분 소요

Global Filter도 이전 글에서 만든 Custom Filter와 비슷한 방식으로 만들 수 있다. (apply() 메서드 지정) 하지만 Global Filter는 “공통” 필터라는 점에서 Custom Filter와 차이가 있다. Custom Filter는 아래와 같이 라우팅 ...

[Spring Cloud Gateway] Custom Filter 적용

1 분 소요

Custom Filter는 사용자 정의 필터로 로그를 출력하거나, 인증을 처리하거나, 로케일을 바꿀 수 있다. 이번에는 직접 Custom Filter를 정의해 등록해보자.