![Page 1: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/1.jpg)
Rest in Practice:Hypermedia and Services
Guilherme Silveira
Wednesday, June 8, 2011
![Page 2: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/2.jpg)
Guilherme Silveira
Wednesday, June 8, 2011
![Page 3: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/3.jpg)
@guilhermecaelum
Wednesday, June 8, 2011
![Page 4: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/4.jpg)
11 years, 1992: “Basic”
Wednesday, June 8, 2011
![Page 5: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/5.jpg)
2002 guj.com.br2003 vraptor
Wednesday, June 8, 2011
![Page 6: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/6.jpg)
2004 extreme programming
2006 scrum
...
Wednesday, June 8, 2011
![Page 7: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/7.jpg)
2009 restfulie
http://restfulie.caelumobjects.com/
Wednesday, June 8, 2011
![Page 8: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/8.jpg)
2010 tectura
http://www.tectura.com.br
Wednesday, June 8, 2011
![Page 9: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/9.jpg)
2004 caelum - daily life
www.caelum.com.br
Wednesday, June 8, 2011
![Page 10: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/10.jpg)
blogs
blog.caelum.com.bragilenomundoreal.com.brblog.caelumobjects.com
Wednesday, June 8, 2011
![Page 11: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/11.jpg)
bank.com
Wednesday, June 8, 2011
![Page 12: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/12.jpg)
calendar.combank.com
Wednesday, June 8, 2011
![Page 13: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/13.jpg)
calendar.com
travel.com
bank.com
Wednesday, June 8, 2011
![Page 14: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/14.jpg)
calendar.com
travel.com company.com
bank.com
Wednesday, June 8, 2011
![Page 15: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/15.jpg)
calendar.com
travel.com company.com
bank.com
Wednesday, June 8, 2011
![Page 16: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/16.jpg)
what is the future of integration over the web?
Wednesday, June 8, 2011
![Page 17: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/17.jpg)
what was REST?
Wednesday, June 8, 2011
![Page 18: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/18.jpg)
Restful
Services
Web
Wednesday, June 8, 2011
![Page 19: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/19.jpg)
Restful
Servicescreate a saas account
Web
Wednesday, June 8, 2011
![Page 20: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/20.jpg)
Restful
Servicescreate a saas account
freeze account
Web
Wednesday, June 8, 2011
![Page 21: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/21.jpg)
Restful
Servicescreate a saas account
freeze account
reactivate account
Web
Wednesday, June 8, 2011
![Page 22: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/22.jpg)
Restful Services
Web
Wednesday, June 8, 2011
![Page 23: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/23.jpg)
Restful Services
http
Web
Wednesday, June 8, 2011
![Page 24: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/24.jpg)
Restful Services
http
port 80
Web
Wednesday, June 8, 2011
![Page 25: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/25.jpg)
Restful Services
http
port 80
firewall heaven
Web
Wednesday, June 8, 2011
![Page 26: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/26.jpg)
Restful
ServicesWeb
Wednesday, June 8, 2011
![Page 27: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/27.jpg)
Restful
Services
xml, json
Web
Wednesday, June 8, 2011
![Page 28: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/28.jpg)
Restful
Services
xml, json
get, post, ...
Web
Wednesday, June 8, 2011
![Page 29: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/29.jpg)
unresttrips.com: flight details
<?xml version="1.0" encoding="UTF-8" standalum="yes"?><flight> <information> <from>sao paulo</from> <to>seoul</to> </information> <value>900.00</value></flight>
Wednesday, June 8, 2011
![Page 30: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/30.jpg)
service locator when integrating:
coupling++
guilherme
unresttrips.com
unrest pay
Wednesday, June 8, 2011
![Page 31: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/31.jpg)
service locator when integrating:
coupling++
guilherme
unresttrips.com
unrest pay
Wednesday, June 8, 2011
![Page 32: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/32.jpg)
resttrips.com: flight details
<?xml version="1.0" encoding="UTF-8" standalum="yes"?><flight> <information> <from>sao paulo</from> <to>seoul</to> </information> <value>900.00</value> <link rel="payment" href="http://resttrips.com/payment/custom"/></flight>
Wednesday, June 8, 2011
![Page 33: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/33.jpg)
resttrips.com: making the payment
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value);
Wednesday, June 8, 2011
![Page 34: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/34.jpg)
resttrips.com: changing its payment provider
<?xml version="1.0" encoding="UTF-8" standalum="yes"?><flight> <information> <from>sao paulo</from> <to>seoul</to> </information> <value>900.00</value> <link rel="payment" href="http://paysite.com/custom"/></flight>
Wednesday, June 8, 2011
![Page 35: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/35.jpg)
dependency injection when integrating:
coupling--
guilherme
resttrips.com
paysite.com
restrips pay
Wednesday, June 8, 2011
![Page 36: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/36.jpg)
dependency injection when integrating:
coupling--
guilherme
resttrips.com
paysite.com
restrips pay
Wednesday, June 8, 2011
![Page 37: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/37.jpg)
i never travel alone
Wednesday, June 8, 2011
![Page 38: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/38.jpg)
my friendsergio
Wednesday, June 8, 2011
![Page 39: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/39.jpg)
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
// send the payment link to another part of the web
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
resttrips.com: sharing a trip
Wednesday, June 8, 2011
![Page 40: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/40.jpg)
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
// send the payment link to another part of the web
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
resttrips.com: sharing a trip
Wednesday, June 8, 2011
![Page 41: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/41.jpg)
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
// send the payment link to another part of the web
flight = Client.at('http://resttrips.com/f/574XR4').get();
confirmation = flight.getLink("payment"). patch(cardInformation, value/2);
resttrips.com: sharing a trip
Wednesday, June 8, 2011
![Page 42: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/42.jpg)
myself = Client.at('http://users.calendar.com') .with(auth).get();
myself.link("calendar").patch(flight.link("self"));
calendar: integrating my systems
Wednesday, June 8, 2011
![Page 43: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/43.jpg)
myself = Client.at('http://users.calendar.com') .with(auth).get();
myself.link("calendar").patch(flight.link("self"));
calendar: integrating my systems
Wednesday, June 8, 2011
![Page 44: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/44.jpg)
me.link("calendar").patch(link_to_birthday_list)me.link("calendar").patch(link_to_hotel_reservation)me.link("calendar").patch(link_to_trip_details)
calendar: more examples
Wednesday, June 8, 2011
![Page 45: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/45.jpg)
so what?
Wednesday, June 8, 2011
![Page 46: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/46.jpg)
so what?
Any update on the flight ==> reflects hereAny update on the hotel ==> reflects hereAny update on the meeting ==> reflects here
Wednesday, June 8, 2011
![Page 47: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/47.jpg)
so what?
Any update on the flight ==> reflects hereAny update on the hotel ==> reflects hereAny update on the meeting ==> reflects here
don’t just u
se, integrate!
Wednesday, June 8, 2011
![Page 48: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/48.jpg)
so what? that was just keeping an URI.
Wednesday, June 8, 2011
![Page 49: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/49.jpg)
so what? that was just keeping an URI.
Remove ==> Cancels the flightRemove ==> Cancels the reservationRemove ==> Emails your coworkers
Wednesday, June 8, 2011
![Page 50: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/50.jpg)
so what? that was just keeping an URI.
Remove ==> Cancels the flightRemove ==> Cancels the reservationRemove ==> Emails your coworkers
do not central
ize control!
Wednesday, June 8, 2011
![Page 51: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/51.jpg)
does our ‘rest’ systems built in
2010work this way?
Wednesday, June 8, 2011
![Page 52: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/52.jpg)
so what? that was just keeping an URI.
Remove ==> Cancels the flightRemove ==> Cancels the reservationRemove ==> Emails your coworkers
Wednesday, June 8, 2011
![Page 53: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/53.jpg)
so what? that was just keeping an URI.
Remove ==> Cancels the flightRemove ==> Cancels the reservationRemove ==> Emails your coworkers
but which format?
Wednesday, June 8, 2011
![Page 54: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/54.jpg)
#json, #xml, #soap #etc?
Wednesday, June 8, 2011
![Page 55: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/55.jpg)
which #json, #xml #etc?
Wednesday, June 8, 2011
![Page 56: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/56.jpg)
exercise
Wednesday, June 8, 2011
![Page 57: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/57.jpg)
so what?
Wednesday, June 8, 2011
![Page 58: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/58.jpg)
so what?
micro formats, media types, rdf etc
Wednesday, June 8, 2011
![Page 59: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/59.jpg)
so what?
micro formats, media types, rdf etc
micro formats
with hyperlinks!
Wednesday, June 8, 2011
![Page 60: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/60.jpg)
integration over the web
Wednesday, June 8, 2011
![Page 61: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/61.jpg)
must ignore
Wednesday, June 8, 2011
![Page 62: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/62.jpg)
bottom up
microformat
mime type?
design by committe
controlled vocabulary
Wednesday, June 8, 2011
![Page 63: LT 08 - Guilherme Silveira - Cache hipermidia](https://reader035.vdocuments.us/reader035/viewer/2022062404/554bc6dfb4c90530298b55fe/html5/thumbnails/63.jpg)
hypermediaintegration over the web
Wednesday, June 8, 2011