CS 190 Lecture Notes: Tweeter ProjectSlide 1 Uniform Resource Locators (URLs) Scheme Host.

Slides:



Advertisements
Similar presentations
HTTP HyperText Transfer Protocol. HTTP Uses TCP as its underlying transport protocol Uses port 80 Stateless protocol (i.e. HTTP Server maintains no information.
Advertisements

1 HTTP and some other odds and ends Nelson Padua-Perez Bill Pugh Department of Computer Science University of Maryland, College Park.
1 HTTP – HyperText Transfer Protocol Part 1. 2 Common Protocols In order for two remote machines to “ understand ” each other they should –‘‘ speak the.
CS320 Web and Internet Programming Handling HTTP Requests Chengyu Sun California State University, Los Angeles.
CS320 Web and Internet Programming Generating HTTP Responses
HTTP Hypertext Transfer Protocol. HTTP messages HTTP is the language that web clients and web servers use to talk to each other –HTTP is largely “under.
How the web works: HTTP and CGI explained
TCP/IP Protocol Suite 1 Chapter 22 Upon completion you will be able to: World Wide Web: HTTP Know how HTTP accesses data on the WWW Objectives.
1 Web Search Interfaces. 2 Web Search Interface Web search engines of course need a web-based interface. Search page must accept a query string and submit.
CS 142 Lecture Notes: URLs and LinksSlide 1 Uniform Resource Locators (URLs) Scheme Host Name.
CS 142 Lecture Notes: HTTPSlide 1 HTTP Request GET /index.html HTTP/1.1 Host: User-Agent: Mozilla/5.0 Accept: text/html, */* Accept-Language:
Client, Server, HTTP, IP Address, Domain Name. Client-Server Model Client Bob Yahoo Server yahoo.com/finance.html A text file named finance.html.
CSC 2720 Building Web Applications Servlet – Getting and Setting HTTP Headers.
 What is it ? What is it ?  URI,URN,URL URI,URN,URL  HTTP – methods HTTP – methods  HTTP Request Packets HTTP Request Packets  HTTP Request Headers.
Web technologies and programming cse hypermedia and multimedia technology Fanis Tsandilas April 3, 2007.
Web Hacking 1. Overview Why web HTTP Protocol HTTP Attacks 2.
DNS and HTTP CS 168. Domain Name Service Host addresses: e.g., – a number used by protocols – conforms to network structure (the “where”)
Simple Web Services. Internet Basics The Internet is based on a communication protocol named TCP (Transmission Control Protocol) TCP allows programs running.
1 HTTP Caching & Cache-Busting for Content Publishers Michael J. Radwin ApacheCon 2005 Wednesday, 14 December 2005.
HTTP Caching & Cache-Busting for Content Publishers Michael J. Radwin O’Reilly Open Source Convention July 28, 2004.
Java Technology and Applications
SUNY Polytechnic Institute CS 490 – Web Design, AJAX, jQuery Web Services A web service is a software system that supports interaction (requesting data,
FTP (File Transfer Protocol) & Telnet
Simple Web Services. Internet Basics The Internet is based on a communication protocol named TCP (Transmission Control Protocol) TCP allows programs running.
CSC 2720 Building Web Applications Getting and Setting HTTP Headers (With PHP Examples)
CP476 Internet Computing Lecture 5 : HTTP, WWW and URL 1 Lecture 5. WWW, HTTP and URL Objective: to review the concepts of WWW to understand how HTTP works.
TCP/IP Protocol Suite 1 Chapter 22 Upon completion you will be able to: World Wide Web: HTTP Understand the components of a browser and a server Understand.
Application Layer 2 Figures from Kurose and Ross
Maryam Elahi University of Calgary – CPSC 441.  HTTP stands for Hypertext Transfer Protocol.  Used to deliver virtually all files and other data (collectively.
© Janice Regan, CMPT 128, Jan 2007 CMPT 371 Data Communications and Networking HTTP 0.
WWW, HTTP, GET, POST, Cookies Svetlin Nakov Telerik Corporation
CS320 Web and Internet Programming Handling HTTP Requests Chengyu Sun California State University, Los Angeles.
1 Introductory material. This module illustrates the interactions of the protocols of the TCP/IP protocol suite with the help of an example. The example.
Proxy Lab Recitation I Monday Nov 20, 2006.
Web Spiders Dan Reeves Bill Walsh HDIW EECS February 2000.
1 CS 4396 Computer Networks Lab TCP/IP Networking An Example.
HyperText Transfer Protocol (HTTP) RICHI GUPTA CISC 856: TCP/IP and Upper Layer Protocols Fall 2007 Thanks to Dr. Amer, UDEL for some of the slides used.
HTTP1 Hypertext Transfer Protocol (HTTP) After this lecture, you should be able to:  Know how Web Browsers and Web Servers communicate via HTTP Protocol.
A Little Bit About Cookies Fort Collins, CO Copyright © XTR Systems, LLC A Little Bit About Cookies Instructor: Joseph DiVerdi, Ph.D., M.B.A.
1-1 HTTP request message GET /somedir/page.html HTTP/1.1 Host: User-agent: Mozilla/4.0 Connection: close Accept-language:fr request.
WWW: an Internet application Bill Chu. © Bei-Tseng Chu Aug 2000 WWW Web and HTTP WWW web is an interconnected information servers each server maintains.
Appendix E: Overview of HTTP ©SoftMoore ConsultingSlide 1.
Operating Systems Lesson 12. HTTP vs HTML HTML: hypertext markup language ◦ Definitions of tags that are added to Web documents to control their appearance.
2: Application Layer 1 Chapter 2: Application layer r 2.1 Principles of network applications  app architectures  app requirements r 2.2 Web and HTTP.
The Basics of HTTP Jason Dean
CIT 383: Administrative ScriptingSlide #1 CIT 383: Administrative Scripting HTTP.
JavaScript, Part 4 Instructor: Charles Moen CSCI/CINF 4230.
HTTP Here, we examine the hypertext transfer protocol (http) – originally introduced around 1990 but not standardized until 1997 (version 1.0) – protocol.
Summer 2007 Florida Atlantic University Department of Computer Science & Engineering COP 4814 – Web Services Dr. Roy Levow Part 1 – Introducing Ajax.
RESTful Web Services What is RESTful?
1 10/19/05CS360 Windows Programming ASP.NET. 2 10/19/05CS360 Windows Programming ASP.NET  ASP.NET works on top of the HTTP protocol  Takes advantage.
Overview of Servlets and JSP
LURP Details. LURP Lab Details  1.Given a GET … call a proxy CGI script in the same way you would for a normal CGI request  2.This UDP perl.
Data Communications and Computer Networks Chapter 2 CS 3830 Lecture 7 Omar Meqdadi Department of Computer Science and Software Engineering University of.
Web Caching. Why Caching? Faster browsing experience for users Cache hit rate Traffic Prioritization Reduce network bandwidth requirements significantly.
JAVA, JEE Training Introduction to Web Harinath Mallepally
Simple Web Services. Internet Basics The Internet is based on a communication protocol named TCP (Transmission Control Protocol) TCP allows programs running.
DEV336. demo HTTP Packet Trace GET / HTTP/1.1 Accept: text/html, application/xhtml+xml, */* Accept-Language: en-US User-Agent: Mozilla/5.0 (compatible;
INTRODUCTION Dr Mohd Soperi Mohd Zahid Semester /16.
© Janice Regan, CMPT 128, Jan 2007 CMPT 371 Data Communications and Networking HTTP 0.
Fiddler and Your Website Robert Boedigheimer. About Me Web developer since 1995 Columnist for aspalliance.com Pluralsight Author 3 rd Degree Black Belt,
Lecture # 1 By: Aftab Alam Department Of Computer Science University Of Peshawar Internet Programming.
Uniform Resource Locators
Uniform Resource Locators (URLs)
HTTP Request Method URL Protocol Version GET /index.html HTTP/1.1
Uniform Resource Locators (URLs)
Uniform Resource Locators
Uniform Resource Locators (URLs)
CSCI-351 Data communication and Networks
Presentation transcript:

CS 190 Lecture Notes: Tweeter ProjectSlide 1 Uniform Resource Locators (URLs) Scheme Host Name Port Number Hierarchical portion Query

CS 190 Lecture Notes: Tweeter ProjectSlide 2 HTTP GET Request GET /statuses/user_timeline?my_id=100 HTTP/1.1 Host: User-Agent: Mozilla/5.0 Accept: text/html, */* Accept-Language: en-us Accept-Charset: ISO ,utf-8 Connection: keep-alive blank line GET /statuses/user_timeline?my_id=100 HTTP/1.1 Host: User-Agent: Mozilla/5.0 Accept: text/html, */* Accept-Language: en-us Accept-Charset: ISO ,utf-8 Connection: keep-alive blank line URLProtocol VersionMethod Headers Body (empty)

CS 190 Lecture Notes: Tweeter ProjectSlide 3 HTTP Response HTTP/ OK Date: Thu, 24 Jul :36:27 GMT Server: Tweeter/1.0 Content-Type: application/json;charset=UTF-8 Content-Length: 266 blank line {"tweets": [{"id": 20006, "user": 100, "time": "Mon Oct 27 18:02:57 PDT 2014", "text": "I’m at home now",}, {"id": 20005, "user": 100, "time": "Mon Oct 27 17:33:57 PDT 2014", "text": "Stuck in traffic"}... ] } HTTP/ OK Date: Thu, 24 Jul :36:27 GMT Server: Tweeter/1.0 Content-Type: application/json;charset=UTF-8 Content-Length: 266 blank line {"tweets": [{"id": 20006, "user": 100, "time": "Mon Oct 27 18:02:57 PDT 2014", "text": "I’m at home now",}, {"id": 20005, "user": 100, "time": "Mon Oct 27 17:33:57 PDT 2014", "text": "Stuck in traffic"}... ] } StatusStatus MessageVersion Headers Body

CS 190 Lecture Notes: Tweeter ProjectSlide 4 HTTP POST Request POST /statuses/update HTTP/1.1 Host: User-Agent: Mozilla/5.0 Accept: text/html, */* Accept-Language: en-us Accept-Charset: ISO ,utf-8 Connection: keep-alive blank line my_id=100&status=Stuck%20in%20traffic POST /statuses/update HTTP/1.1 Host: User-Agent: Mozilla/5.0 Accept: text/html, */* Accept-Language: en-us Accept-Charset: ISO ,utf-8 Connection: keep-alive blank line my_id=100&status=Stuck%20in%20traffic URLProtocol VersionMethod Headers Body (form data) Parameters

● Simple values: "This is a string" 99.6 ● Arrays: [14, 32, "California", 1.001] ● Objects (named properties): {"name": "Alice", "age": 24, "salary": } ● Nested values: {"name": "Alice", "gpa": 3.5, "friends": ["Bill", "Carol", "David"]} CS 190 Lecture Notes: Tweeter ProjectSlide 5 JSON Notation

POST /friendships/create?my_id=100&user_id=200  User 100 becomes a follower of user 200 POST /friendships/destroy?my_id=100&user_id=200  User 100 is no longer a follower of user 200 GET /friends/ids.json?user_id=100  Return ids for all users that user 100 is following: [100, 84, 290, 16] GET /followers/ids.json?user_id=100  Return ids for all the users following user 100: [200, 374, 82, 95, 1003] CS 190 Lecture Notes: Tweeter ProjectSlide 6 Tweeter Interface

POST /statuses/update?my_id=100&status=Sleepy  Create a new tweet for user 100 GET /statuses/user_timeline.json?my_id=100 &count=20&max_id=25000  Return the 20 most recent tweets from user 100 (exclude tweets with ids > 25000) {"tweets": [{"id": 20006, "user": 100, "time": "Mon Oct 27 18:02:57 PDT 2014", "text": "I’m at home now"}, {"id": 20005, "user": 100, "time": "Mon Oct 27 17:33:57 PDT 2014", "text": "Stuck in traffic"}... ] } CS 190 Lecture Notes: Tweeter ProjectSlide 7 Tweeter Interface, cont’d

GET /statuses/home_timeline.json?my_id=100 &count=10&max_id=25000  Return the 20 most recent tweets from user 100 and all users followed by user 100 (exclude tweets with ids > 25000) CS 190 Lecture Notes: Tweeter ProjectSlide 8 Tweeter Interface, cont’d