-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat : [Network] HTTP κ°κ΄(1) (#13)
- Loading branch information
Showing
2 changed files
with
53 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
> μ°Έκ³ μλ£ : HTTP μλ²½ κ°μ΄λ - μΉμ μ΄λ»κ² λμνλκ° | ||
# 1μ₯ HTTP κ°κ΄ | ||
|
||
## 1. HTTP | ||
|
||
- HTTP : Hypertext Transfer Protocol | ||
- World Wide Web μ κΈ°λ³Έ μμ : HTTP ν΄λΌμ΄μΈνΈ / HTTP μλ² | ||
- HTTP νλ‘ν μ½μ ν΅ν΄ ν΅μ | ||
|
||
## 2. 리μμ€ | ||
|
||
- μΉ μλ² : 리μμ€ κ΄λ¦¬ λ° μ 곡 | ||
|
||
1. λ―Έλμ΄ νμ MIME : Multipurpose Internet Mail Extensions | ||
- λ©ν°λ―Έλμ΄ μ½ν μΈ λ₯Ό κΈ°μ & κ°λ° κ°λ₯ | ||
- μΉ μλ² : HTTP obj μ MIME νμ λΆμ -> λ€λ£° μ μλ κ°μ²΄μΈμ§ νμΈ | ||
- e.g. `text/html` HTML λ¬Έμ, `image/jpeg` JPEG μ΄λ―Έμ§ λ± | ||
2. URI : Uniform Resource Identifier | ||
- κ° μΉ μλ² λ¦¬μμ€ μ΄λ¦ | ||
- ν΄λΌμ΄μΈνΈκ° URI λ₯Ό ν΅ν΄ νΉμ 리μμ€μ μ κ·Ό κ°λ₯ | ||
`http://www.joes-hw.com/specials/saw-blade.gif` | ||
- scheme `http://` : HTTP protocol | ||
- internet addr of server `www.joes-hw.com` : www.joes-hw.com μΌλ‘ μ΄λ | ||
- resource in server `/specials/saw-blade.gif` : /specials/saw-blade.gif λΌκ³ λΆλ¦¬λ 리μμ€ μ§μΉ | ||
3. URL : Uniform Resource Locator | ||
- 리μμ€ μλ³μμ νν νν | ||
- νΉμ μλ²μ ν 리μμ€μ λν ꡬ체μ μμΉ | ||
- μ€λλ , URI == URL | ||
|
||
## 3. νΈλμμ | ||
|
||
- HTTP νΈλμμ = HTTP μμ² (c -> s) + HTTP μλ΅ (s -> c) | ||
|
||
1. HTTP λ©μλ | ||
- 1 method in 1 HTTP request msg | ||
- GET : s -> c λ‘ μ§μ 리μμ€ λ³΄λ΄μ€ | ||
- PUT : c -> s μΈ λ°μ΄ν°λ₯Ό μ§μ ν μ΄λ¦μ 리μμ€λ‘ μ μ₯ν΄μ‘° | ||
- DELETE : μ§μ ν 리μμ€λ₯Ό s μμ μμ ν΄μ‘° | ||
- POST : c data λ₯Ό s gateway app μΌλ‘ 보λ΄μ‘° | ||
- HEAD : μ§μ ν 리μμ€μ λν μλ΅μμ HTTP header λ§ μ‘° | ||
2. μν μ½λ | ||
- μν μ½λ in λͺ¨λ HTTP response | ||
- c μ μμ²μ λν λ°μ | ||
- μν μ½λ & resson phrase | ||
- 200 OK | ||
- 200 Document attached | ||
3. λλμ νΈλμμ μν | ||
- μΉ νμ΄μ§ == 리μμ€μ λͺ¨μμ§ | ||
|
||
## 4. λ©μμ§ | ||
|
||
![HTTP MSG](ny_http_msg.png) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.