<commit_before>#+TITLE: HTTP

* Table of Contents :TOC_2_gh:
 - [[#reference][Reference]]
   - [[#cache-control][Cache Control]]
 - [[#details][Details]]
   - [[#url-vs-uri-vs-urn][URL vs URI vs URN]]

* Reference
** Cache Control
- https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control

* Details
** URL vs URI vs URN
- https://stackoverflow.com/questions/176264/what-is-the-difference-between-a-uri-a-url-and-a-urn

| Name  | Example                                 | Note                                                                                                         |
|-------+-----------------------------------------+--------------------------------------------------------------------------------------------------------------|
| ~URI~ | ~https://www.google.co.kr/search?q=uri~ |                                                                                                              |
| ~URL~ | ~https://www.google.co.kr/search~       | Subset of ~URI~, contains only about location                                                                |
| ~URN~ | ~urn:google:search:uri~                 | Subset of ~URI~, doesn't necessarily tell you how to locate it on the internet. Usually Prefixed with ~urn:~ |


[[file:img/screenshot_2017-06-03_15-46-11.png]]<commit_msg>Write about HTTP cache control<commit_after>#+TITLE: HTTP

* Table of Contents :TOC_2_gh:
 - [[#reference][Reference]]
   - [[#cache-control][Cache Control]]
 - [[#details][Details]]
   - [[#url-vs-uri-vs-urn][URL vs URI vs URN]]

* Reference
** Cache Control
- https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control

*** Request
#+BEGIN_EXAMPLE
  Cache-Control: max-age=<seconds>
  Cache-Control: max-stale[=<seconds>]
  Cache-Control: min-fresh=<seconds>
  Cache-Control: no-cache 
  Cache-Control: no-store
  Cache-Control: no-transform
  Cache-Control: only-if-cached
#+END_EXAMPLE

*** response
#+BEGIN_EXAMPLE
  Cache-Control: must-revalidate
  Cache-Control: no-cache
  Cache-Control: no-store
  Cache-Control: no-transform
  Cache-Control: public
  Cache-Control: private
  Cache-Control: proxy-revalidate
  Cache-Control: max-age=<seconds>
  Cache-Control: s-maxage=<seconds>
#+END_EXAMPLE

* Details
** URL vs URI vs URN
- https://stackoverflow.com/questions/176264/what-is-the-difference-between-a-uri-a-url-and-a-urn

| Name  | Example                                 | Note                                                                                                         |
|-------+-----------------------------------------+--------------------------------------------------------------------------------------------------------------|
| ~URI~ | ~https://www.google.co.kr/search?q=uri~ |                                                                                                              |
| ~URL~ | ~https://www.google.co.kr/search~       | Subset of ~URI~, contains only about location                                                                |
| ~URN~ | ~urn:google:search:uri~                 | Subset of ~URI~, doesn't necessarily tell you how to locate it on the internet. Usually Prefixed with ~urn:~ |


[[file:img/screenshot_2017-06-03_15-46-11.png]]
{'fraction_non_alphanumeric': 0.2202916537387527, 'fraction_numerical': 0.013031337263419174, 'mean_word_length': 1.2849043231750532, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 8, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 26, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2077679', 'n_tokens_mistral': 877, 'n_tokens_neox': 817, 'n_words': 163}