Skip to Content
이벤트 기반 마이크로서비스 구축
book

이벤트 기반 마이크로서비스 구축

by 이일웅, 애덤 벨메어
May 2021
Beginner to intermediate
380 pages
7h 48m
Korean
Hanbit Media, Inc.
Content preview from 이벤트 기반 마이크로서비스 구축
176
이벤트 기반 마이크로서비스 구축
스트림에 이벤트를 게시할 수 있습니다. 트랜잭션을 지원하지 않는 다른 이벤트 브로커를 사용
할 경우에는 클라이언트가 ‘실제로 한 번 처리’하는 로직을 구현해야 합니다. 다음 절에서 이 두
가지 방법을 살펴보겠습니다. 여러분의 마이크로서비스에는 어떻게 적용하면 좋을지 한번 생
각해보세요.
TIP
트랜잭션은 아주 강력한 기능이라서 아파치 카프카가 경쟁자들보다 중요한 강점을 지니게 됐습니다. 트랜잭션
이 없다면 원자적으로 이벤트를 생산하기 위해 복잡한 리팩터링이 불가피할 것입니다.
7.6.1
예제: 재고 회계 서비스
어떤 품목의 재고가 부족하면 알림 이벤트를 발행하는 재고 회계 서비스
stock
accounting
service
가 있
다고 합시다. 이 마이크로서비스는 제품별 입고/입출 수량에 따라 현재 가용한 재고 정보를 산
출합니다. 고객에게 제품을 판매하여 물건이 빠지거나 제품이 손상, 도난을 당해 손실이 발생
하면 재고를 차감하는 이벤트가, 배송된 화물을 수취하거나 고객이 반품한 제품을 받으면 재고
를 증가시키는 이벤트가 각각 발생합니다. 편의상 이 두 이벤트를 동일한 이벤트 스트림에 쓰
겠습니다 (그림
7
-
8
).
재고 변경 스트림
메타데이터 내 오프셋
드라이버
스트림
읽기
재고 테이블
데이터베이스
쓰기
애플리케이션 컨테이너
집계기
컨슈머 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

헤드 퍼스트 자바(3판)

헤드 퍼스트 자바(3판)

케이시 시에라, 버트 베이츠
클라우드 핀옵스: 비용은 최소화 운영은 최적화

클라우드 핀옵스: 비용은 최소화 운영은 최적화

오성근, J. R. 스토먼트, 마이크 풀러

Publisher Resources

ISBN: 9791162244173