Search
Duplicate
โ˜•

web.reactive

DispatcherHandler

โ€ข
HttpServer(Netty) ์˜ onStateChange ํ•จ์ˆ˜ mono.subscribe() ๋ฅผ ํ†ตํ•ด handle ์ด ํ˜ธ์ถœ๋œ๋‹ค.
โ€ข
๋จผ์ € handlerMappings ๊ฐ€ null ์ธ์ง€ ํ™•์ธ
โ€ข
๋“ฑ๋ก๋œ handlerMappings ๋ฅผ ๋Œ๋ฉด์„œ handler ๋ฅผ ์ฐพ๋Š”๋‹ค.
โ€ข
๋Œ๋‹ค๊ฐ€ ์—๋Ÿฌ ๋ฐœ์ƒํ•˜๋ฉด ์—๋Ÿฌ ๊ฒฐ๊ณผ ์ƒ์„ฑ
โ€ข
๊ทธ๋ฆฌ๊ณ  handlerRequestWith(exchange, handler) ํ•จ์ˆ˜ ์‘๋‹ต
โ—ฆ
์•Œ๋งž์€ handlerAdapter ๋ฅผ ์ฐพ์•„ Mono<HandlerResult> ์‘๋‹ต
โ—ฆ
result ๋ฅผ handle ํ•˜๊ณ  Mono<Void> ์‘๋‹ต

DispatcherExceptionHandler

โ€ข
๊ตฌํ˜„์ฒด๋Š” RequestMappingHandlerAdapter ํ•˜๋‚˜
โ€ข
๊ถ๊ธˆ์ : RequestMapping ์ด๋ผ๋Š” ๋„ค์ด๋ฐ์€ ์™œ?
โ—ฆ
requestMapping ์€ ์ „ํ†ต MVC ์—์„œ ์“ฐ์ด๋Š”๋ฐ

HandlerMapping

โ€ข
Handler ์ฐพ๊ธฐ
โ€ข
์š”์ฒญ(http method, endpoint, request params, path variables ๋“ฑ)์— ํ•ด๋‹นํ•˜๋Š” ํด๋ž˜์Šค-ํ•จ์ˆ˜ ์ฐพ์Œ

HandlerAdapter

โ€ข
์š”์ฒญ์— ํ•ด๋‹นํ•˜๋Š” ํด๋ž˜์Šค-ํ•จ์ˆ˜(handler) ์‹คํ–‰ ๋ฐ ์‘๋‹ต ๋ฐ›๊ธฐ

HandlerResult

โ€ข
dto ๋Š๋‚Œ