결제 전환 목표 아키텍처 정의 (2/2) (iss-478981daa4be)
All checks were successful
ci / test (pull_request) Successful in 8s
All checks were successful
ci / test (pull_request) Successful in 8s
This commit is contained in:
parent
9f1c3535a6
commit
d6a5bdaea6
1 changed files with 31 additions and 0 deletions
31
docs/architecture/transaction-sequence.md
Normal file
31
docs/architecture/transaction-sequence.md
Normal file
|
|
@ -0,0 +1,31 @@
|
||||||
|
```mermaid
|
||||||
|
sequenceDiagram
|
||||||
|
participant User
|
||||||
|
participant PaymentGateway
|
||||||
|
participant Database
|
||||||
|
|
||||||
|
%% 정상 흐름 %%
|
||||||
|
User->>PaymentGateway: 결제 요청
|
||||||
|
PaymentGateway->>User: 결제 승인
|
||||||
|
User->>Database: 거래 기록 저장
|
||||||
|
Database-->>User: 거래 성공
|
||||||
|
%% 커밋 %%
|
||||||
|
User->>Database: 커밋
|
||||||
|
Database-->>User: 커밋 완료
|
||||||
|
|
||||||
|
%% 외부 실패 %%
|
||||||
|
User->>PaymentGateway: 결제 요청
|
||||||
|
PaymentGateway-->>User: 결제 실패
|
||||||
|
%% 롤백 %%
|
||||||
|
User->>Database: 롤백
|
||||||
|
Database-->>User: 롤백 완료
|
||||||
|
|
||||||
|
%% DB 실패 %%
|
||||||
|
User->>PaymentGateway: 결제 요청
|
||||||
|
PaymentGateway->>User: 결제 승인
|
||||||
|
User->>Database: 거래 기록 저장
|
||||||
|
Database-->>User: DB 오류
|
||||||
|
%% 롤백 %%
|
||||||
|
User->>Database: 롤백
|
||||||
|
Database-->>User: 롤백 완료
|
||||||
|
```
|
||||||
Loading…
Add table
Add a link
Reference in a new issue