Skip to content

Commit

Permalink
summarize payment system
Browse files Browse the repository at this point in the history
  • Loading branch information
freemanzhang committed Jan 29, 2017
1 parent 56f4c48 commit df22aa2
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions paymentSystem.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
# payment system
# Payment system

## Append-only
## Stability
## Payment process
1. Retrieve users that needs charging from SQS and corresponding info: subscription ID, charge fees.
2. Retrieve user payment method from MySQL.
3. Prepare payment request based on obtained info.
4. Check whether the request is pending (Such payment request is sent, but not finished due to server failure or third party payment problems), if yes, ignore (avoid paying twice).
5. Send request to Third Party Payment, retry or failure process ( send payment failure back to SQS )
6. If OK response from Third Party, update pending list, send confirmation back to SQS.

0 comments on commit df22aa2

Please sign in to comment.