-
Notifications
You must be signed in to change notification settings - Fork 16
/
web_architecture.theory.txt
86 lines (78 loc) · 5.83 KB
/
web_architecture.theory.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
┏━━━━━━━━━━━━━━━━━━━━━━┓
┃ WEB_ARCHITECTURE ┃
┗━━━━━━━━━━━━━━━━━━━━━━┛
STANDARDS ==> #W3C TAG findings:
# - "Architecture of the World Wide Web, Volume One"
# - "Authoritative metadata"
SUMMARY ==> #Web: separate identification (URI), interaction (URI scheme) and format (MIME).
#Metadata:
# - can be inside any of them, and describe any of them
# - encapsulating > embedded > external
┌─────────────┐
│ GENERAL │
└─────────────┘
INTERNET ==> #Network of all networks
#Includes the web, but also other technologies: email, FTP and any other possible protocol
WEB ==> #Global set of resources:
# - identified and linking to each other using URIs
# - represented using MIME types
#Architecture provides orthogonality by separating resource into:
# - identification (presentation|view):
# - i.e. URIs
# - good identifier should enforce:
# - sameness (global)
# - no ambiguity
# - uniqueness (no aliases)
# - orthogonality: should not be bound to specific URI scheme nor MIME type
# - interaction (controller):
# - i.e. URI schemes
# - sometimes connected to protocols, but not necessary
# - good interaction should:
# - avoid dead links
# - link resources to each other using URIs or #HASH
# - orthogonality: should not retrict URI syntax, and allow using any MIME type
# - formats (representation|content|model):
# - i.e. MIME types
# - good format should allow:
# - extensions
# - versioning
# - orthogonality: should allow embedding any URI with any URI scheme
#Order: URI -> interaction -> format
#Often used technologies include HTTP, HTML
┌──────────────┐
│ METADATA │
└──────────────┘
METADATA ==> #Can be inside:
# - URI, e.g. DATE in tag: URI
# - interaction, e.g. HTTP header
# - representation, e.g. HTML tag
#Can describe:
# - URI, e.g. Link [S] rel
# - interaction, e.g. Date [S]
# - representation, e.g. Content-Type [S]
#Can be:
# - encapsulating:
# - what it contains, following order: URI -> interaction -> representation
# - e.g. Content-Type [S]
# - has priority over embedded:
# - sender carries intention, so can provide different metadata for same message
# - e.g. same file can be sent as Content-Type: plain/text [S] or as Content-Type: application/json [S] depending on
# sender intention
# - easier to provide metadata for sender than for receiver
# - e.g. server knows Content-Type [S] or Date [S], but it's hard for client to guess it
# - embedded:
# - itself, i.e. URI|interaction|representation describing itself
# - e.g. Date [S], <meta>
# - has priority over external:
# - since external, is not authoritative
# - allow changing content without updating links
# - external:
# - another resource, i.e. URI|interaction|representation describing URI
# - e.g. Link [S], <link>
#Conflicts:
# - priority: encapsulating > embedded > external
# - should be detected
# - must give option for user to be prompted for consent
#If not provided:
# - can guess
# - but should not use a default