-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathrest.html
307 lines (265 loc) · 8.94 KB
/
rest.html
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<title>Web Services REST-Style: Universal Identifiers, Formats & Protocols</title>
<meta name="generator" content="Slide Show (S9) 2.0.0 on Ruby 1.9.2 (2011-07-09) [i386-mingw32]">
<meta name="author" content="Your Name Here" >
<!-- helper/macro that lets you add (CSS3) gradient using headers
see http://slideshow.rubyforge.org/themes.html
-->
<!-- S6 style sheet links -->
<link rel="stylesheet" href="rest.css" media="projection" id="styleProjection">
<link rel="stylesheet" href="s6/screen.css" media="screen" id="styleScreen">
<link rel="stylesheet" href="s6/print.css" media="print">
<!-- S6 JS -->
<script src="s6/jquery.js"></script>
<script src="s6/jquery.slideshow.js"></script>
<script>
$(document).ready( function() {
Slideshow.init();
} );
</script>
<!-- Better Browser Banner for Microsoft Internet Explorer (IE) -->
<!--[if IE]>
<script src="s6/jquery.microsoft.js"></script>
<![endif]-->
</head>
<body>
<div class="layout">
<div id="header"></div>
<div id="footer">
<h1>Your Footer Here</h1>
<h2>Your Subfooter Here</h2>
</div>
</div>
<div class="presentation">
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>Web Services REST-Style<br>Universal Identifiers, Formats & Protocols</h1>
<p>Agenda</p>
<ul>
<li>What’s REST?</li>
<li>Universal Identifiers, Formats & Protocols</li>
<li>The Holy REST Trinity – Noun, Verbs, Types</li>
<li>REST Design Principles</li>
<li>Architecture Astronaut REST Speak</li>
</ul>
<hr />
<!-- begin help -->
<div class='help projection'>
<p><strong>Slide Show Keyboard Controls (Help)</strong></p>
<table>
<tr>
<td> Action </td>
<td> Key </td>
</tr>
<tr>
<td> Go to next slide </td>
<td> Space Bar, Right Arrow, Down Arrow, Page Down, Click Heading </td>
</tr>
<tr>
<td> Go to previous slide </td>
<td> Left Arrow, Up Arrow, Page Up </td>
</tr>
<tr>
<td> Toggle between slideshow and outline view (Ø) </td>
<td> T </td>
</tr>
<tr>
<td> Show/hide slide controls (Ø « ») </td>
<td> C, Move mouse to bottom right corner </td>
</tr>
<tr>
<td> Zoom in, zoom out, zoom reset (100%) </td>
<td> Control<code>+</code>Plus, Control<code>+</code>Minus, Control<code>+</code><code>0</code> </td>
</tr>
</table>
</div>
<!-- end help -->
</div>
<div class='slide s9_gradient_linear_silver_white_silver_white'>
<!-- _S9SLIDE_ -->
<h1 class="fullscreen">Part 1 – What’s REST?</h1>
<p><!-- _S9STYLE_ s9_gradient_linear_silver_white_silver_white --></p>
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>What’s REST?</h1>
<p>Representational State Transfer (REST) – Meaningless Acronym? Wordplay?</p>
<blockquote>
<p>rest – n. – peace, ease, or refreshment resulting from the insight that the web works</p>
</blockquote>
<p>No matter what vendors tell you – no need to “Light Up the Web” – relax – built on an <strong>open architecture using universal identifiers, formats & protocols and <em>evolving</em> open standards</strong> – no need to reinvent the wheel and sign-up for single-vendor offerings.</p>
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>What’s REST? (Cont’d)</h1>
<!-- begin left {} -->
<table width='100%'><tr><td width='50%' markdown='block' style='vertical-align: top;'>
<h3>Narrow Definition</h3>
<p>Alternative to BigCo Web Services:</p>
<ul>
<li><acronym title="Simple Object Access Protocol">SOAP</acronym></li>
<li><acronym title="Web Service Specs">WS</acronym>-*)<sup class="footnote" id="fnr1"><a href="#fn1">1</a></sup> and</li>
<li><acronym title="Remote Procedure Call">RPC</acronym>-Style Web Services (<acronym title="Extensible Markup Language">XML</acronym>-<acronym title="Remote Procedure Call">RPC</acronym>)</li>
</ul>
</td>
<!-- end left -->
<!-- begin right {} -->
<td width='50%' markdown='block' style='vertical-align: top;'>
<h3>Broad Definition</h3>
<p>Best Practices for Designing Web Services for a Unified Human and Programable Web</p>
</td></tr></table>
<!-- end right -->
<p class="footnote" id="fn1"><a href="#fnr1"><sup>1</sup></a> WS-* = Web Service Specs including WS-Transfer, WS-Addressing, WS-Eventing,
WS-Security, WS-Federation, WS-Trust, and many more.</p>
</div>
<div class='slide s9_gradient_linear_silver_white_silver_white'>
<!-- _S9SLIDE_ -->
<h1 class="fullscreen">Part 2 – Universal Identifiers, Formats & Protocols</h1>
<p><!-- _S9STYLE_ s9_gradient_linear_silver_white_silver_white --></p>
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>Universal Identifiers, Formats & Protocols<br>The Holy Trinity</h1>
<!-- begin left {} -->
<table width='100%'><tr><td width='50%' markdown='block' style='vertical-align: top;'>
<!-- begin step {} -->
<div class='step' markdown='block'>
<h3>Identifiers</h3>
<ul>
<li>URLs (Uniform Resource Locator)</li>
<li>URIs (Uniform Resource Identifier)</li>
</ul>
</div>
<!-- end step -->
<!-- begin step {} -->
<div class='step' markdown='block'>
<h3>Formats</h3>
<ul>
<li>HTML (HyperText Markup Language)</li>
<li>XML (Extensible Markup Language)</li>
</ul>
</div>
<!-- end step -->
</td>
<!-- end left -->
<!-- begin right {} -->
<td width='50%' markdown='block' style='vertical-align: top;'>
<!-- begin step {} -->
<div class='step' markdown='block'>
<h3>Protocols</h3>
<ul>
<li>HTTP (HyperText Transfer Protocol)</li>
<li>AtomPub (Atom Publishing Protocol)</li>
</ul>
</div>
<!-- end step -->
</td></tr></table>
<!-- end right -->
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>The Holy REST Trinity – Noun, Verbs, Types</h1>
<table id="restspeak">
<tr>
<th>REST-Speak </th>
<th></th>
<th>Internet-Speak </th>
<th></th>
<th>Plain Old English </th>
</tr>
<tr>
<td> Verbs </td>
<td> ⇔ </td>
<td> Protocols </td>
<td> ⇔ </td>
<td> Communication & Data Exchange Rules </td>
</tr>
<tr>
<td> Nouns </td>
<td> ⇔ </td>
<td> Identifiers </td>
<td> ⇔ </td>
<td> Names, Addresses </td>
</tr>
<tr>
<td> Types </td>
<td> ⇔ </td>
<td> Formats </td>
<td> ⇔ </td>
<td> Documents, Feeds, Photos, Videos, Music, etc. </td>
</tr>
</table>
<p> </p>
<table id="restspeak2">
<tr>
<th>REST-Speak </th>
<th>Examples </th>
</tr>
<tr>
<td> Verbs </td>
<td> ⇒ <acronym title="HyperText Transfer Protocol">HTTP</acronym> GET, POST, PUT, DELETE </td>
</tr>
<tr>
<td> Nouns </td>
<td> ⇒ <code>flickr.com/photos/tag/wien</code>, <code>deli.cio.us/tag/wien</code>, etc. </td>
</tr>
<tr>
<td> Types </td>
<td> ⇒ <acronym title="HyperText Markup Language">HTML</acronym>, <acronym title="Really Simple Syndication">RSS</acronym>, <acronym title="Portable Network Graphics">PNG</acronym>, etcetera </td>
</tr>
</table>
</div>
<div class='slide s9_gradient_linear_silver_white_silver_white'>
<!-- _S9SLIDE_ -->
<h1 class="fullscreen">Part 3 – Design Principles & Architecture</h1>
<p><!-- _S9STYLE_ s9_gradient_linear_silver_white_silver_white --></p>
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>REST Design Principles</h1>
<ul>
<li>Idenifiers Matter ⇒ Choose Great Names</li>
<li>Open Formats Matter ⇒ Avoid Vendor Lock-In</li>
<li>Protocols Matter ⇒ Learn more about HTTP and Use Best Practices
<ul>
<li>Use HTTP GET for Read-Only/Side-Effect-Free Requests</li>
<li>Use HTTP Accept Headers for Format Selection</li>
<li>Use Full HTTP Method Vocabulary (GET, POST, PUT, DELETE)</li>
</ul></li>
</ul>
<ul>
<li>No Web without Linking and No Linking without Identifiers!</li>
<li>(Stateless) Resource Representation ⇒ Open Format + Identifier e.g. <acronym title="HyperText Markup Language">HTML</acronym> + <acronym title="Uniform Resource Identifier">URI</acronym></li>
</ul>
</div>
<div class='slide '>
<!-- _S9SLIDE_ -->
<h1>Architecture Astronaut REST Speak</h1>
<ul>
<li>REST-y</li>
<li>REST-ful</li>
</ul>
<ul>
<li>Resource-Oriented Architecure (ROA)</li>
<li>Web-Oriented Architecure (WOA)</li>
</ul>
<ul>
<li>REST-RPC-Hybrid – Three Web Service Architectures:
<ol>
<li>REST</li>
<li>REST-RPC Hybrid</li>
<li>RPC<sup class="footnote" id="fnr1"><a href="#fn1">1</a></sup></li>
</ol></li>
</ul>
<p class="footnote" id="fn1"><a href="#fnr1"><sup>1</sup></a> RPC = Remote Procedure Call</p>
</div>
<div class='slide s9_gradient_linear_silver_white_silver_white'>
<!-- _S9SLIDE_ -->
<h1 class="fullscreen">The End – Thank You</h1>
<p><!-- _S9STYLE_ s9_gradient_linear_silver_white_silver_white --></p></div>
</div><!-- presentation -->
</body>
</html>