Networking Flashcards
(37 cards)
What is a client?
A device or program that requests and receives services from a server.
What is a server?
A program or device that stores and provides data to others in a network.
What is the relationship between a client and server?
A client initiates requests for services, which are provided by a server.
What do 2xx HTTP status codes indicate?
A request successfully received and accepted by the server.
What do 3xx HTTP status codes indicate?
Further action is required to complete the request - typically involves redirection.
What do 4xx HTTP status codes indicate?
Client error - there is an issue with the request itself or the client’s actions.
What do 5xx HTTP status codes indicate?
Server error meant the server was unable to complete the request.
What is HTTP?
Hypertext Transfer Protocol - a set of rules that dictate how information will be transferred between networked devices.
What is a HTTP header?
A field of an HTTP request/response that passes additional related metadata - like content-type and autorization.
What are HTTP methods used for?
To indicate the action a client would like to perform on a given resource.
What is the default HTTP method for the curl
command-line tool?
GET
; You can also specify a method using -X
What is JSON?
JavaScript Object Notation - a data-interchange format designed to send information between different machines/services.
What are the benefits of JSON?
- Human & machine-readable
- Lightweight
- Supported by many programming languages
What does a DNS (Domain Name System) server do?
It translates human-readable domain names (e.g. www.google.com) into their corresponding IP addresses.
Commonly referred to as a ‘phonebook of the internet’.
What is a CLI?
Command-line interface - a text-based interface where you can input commands to interact with a computer’s OS.
What does TCP stand for? Where is it used?
Transmission Control Protocol - a networking protocol used for reliable and ordered delivery of data.
Ensures data packets arrive in correct order and w/out corruption.
What does UDP stand for? Where is it used?
User Datagram Protocol - a data transport protocol used to send data at speed (connectionless, less reliable than TCP).
What is WebSockets? What is used for?
A technology that facilitates bi-directional, real-time communication over a single, consistent TCP connection. It is used for typing notifications, for example.
What is an API?
Application Programming Interface - a set of rules governing communication and data exchange between multiple software programs.
What are the main features of RESTful APIs?
- Client-server separation
- Stateless
- Caching
- Uniform interface
- Layered system
- Code-on-demand
See here for more detail on each feature (IBM article)
Which HTTP method creates a new resource?
POST
Which HTTP method retrieves information?
GET
What does the PUT HTTP method do?
Overwrites an entire resource with a new version.
What does the PATCH HTTP method do?
Applies partial updates to an existing resource.