- 백엔드 플로우
- App/Web -> Auth -> API -> Webserver -> logging(elasticsearch), queue(kafka, rabbitMQ), file storage(S3)
- HTTP sequence flows from a request to a response
- Network level: URL -> DNS -> 3-way handshakes -> TLS
- Application level: HTTP Request -> Server Processing(AWS - Node - DB) -> HTTP Response
- invariant: a condition that holds true(e.g., x > y).
- graceful(return) vs ungraceful(return exception)
- HTTP method: Put: 전체변경, Patch: 부분변경
- Get - recommended: SHOULD NOT use body (RFC7231, RFC9110.-Although%20request%20message%20framing%20is%20independent%20of%20the%20method%20used%2C%20contentHTTP%20communication%20are%20often%20unaware%20of%20intermediaries%20along%20the%20request%20chain.-%C2%B6))
- Authentication and authorisation
- Open Authorisation(OAuth2.0): It is a way for users to grant websites or applications access to their information without giving away their passwords.
- Flow: authorisation code → credentials → access token
- Client ↔ Authorisation Server: authorisation code
- Resource Owner ↔ Authorisation Server: credentials
- Client ↔ Authorisation Server: access token
- Atomicity
- two-phase commit (Coordinator), Saga pattern, (if shared DB) queryRunner, Message Queue
- Brower cache
- predictable causes: cache-control or expires -> persist 404 response for a while.
- Speed-up loading for static content
- Stores copie of these resources in cache
Problem: Special character(/, :) in URL, Solution: URL encoding
Problem: Many values in a request body are used to map function’s params, Solution: DTO + Pipes(filtering or validation + type check)
snake_case
kebab-case
PascalCase
calmelCase