Open pbg0205 opened 1 year ago
μ°μ μ’μ κΈ κ°μ¬νλλ€!
λ€μκ³Ό κ°μ΄ μλλ Query, Command μλΉμ€ λΆλΆλ€μ νΌμ¬λλ‘ λ³κ²½λλλ‘ κ΅¬ννμμ΅λλ€!
@Service
@RequiredArgsConstructor
public class PostServiceGateway implements CommandService<PostCreateRequest>, QueryService {
private final PostCommandService postCommandService; // νΌμ¬λλ‘
private final PostQueryService postQueryService; // νΌμ¬λλ‘
ππ»ββοΈ μ μ μ¬ν
Facade κ³μΈ΅μ νλ μΆκ°νλ λ°©λ²μ λν΄ κ³ λ―Ό
ν¨μλ ν¨ν΄?
ν¨μλ ν¨ν΄μ μ₯μ
νμ¬ Service λ μ΄μ΄κ° μ°Έμ‘°λ₯Ό νκ³ μλ μμΉ
PostCommandService
PostQueryService
π μ°Έκ³ μ¬ν
곡μ ν λ΄μ©, λ νΌλ°μ€, μΆκ°λ‘ λ°μν κ²μΌλ‘ μμλλ μ΄μ, μ€ν¬λ¦°μ· λ±μ λ£μ΄ μ£ΌμΈμ.