More articles: page 1

These articles are a collection of knowledge gems I’ve gathered over time on a range of computer science topics.

What is an API?

One of the joys of studying computer science is spotting a familiar concept in new surroundings. It’s a wonderful “aha!” moment as you almost literally feel your mind reaching some deeper insight.

In this post, we will answer the common question “what is an Application Programming Interface (API)?”. I’ll illustrate it with various examples of APIs throughout the software stack. In doing so I hope to develop your intuition for when and why APIs are so useful. I can’t quite promise deep insights but I’ll do my best!

Read more »

This post is part of a series:

  1. Introduction
  2. Protocols
  3. Internet Protocol
  4. User Datagram Protocol
  5. Transmission Control Protocol
  6. Domain Name System

Welcome to the final post in this series! It’s been a long time coming, I know. Unfortunately, various life things got in the way and prevented me writing as much as I’d have liked. But fear delay no more! In this post, we’ll round off the series by looking at the Domain Name System (DNS).

Read more »

This post is part of a series:

  1. Introduction
  2. Protocols
  3. Internet Protocol
  4. User Datagram Protocol
  5. Transmission Control Protocol
  6. Domain Name System

Let’s get some services! In previous posts, I talked a whole load about how the transport layer provides communication services before presenting you with UDP, which provides barely any services. The Transmission Control Protocol (TCP) is the main transport layer protocol on the Internet and it provides many useful services.

It pairs very nicely with IP, such that you’ll commonly see them joined together as TCP/IP. It’s impressive that IP can cross physical network boundaries, but as a means of communication it isn’t very easy to use. Delivery is unreliable and you have to break messages into packets and reconstruct them on receipt. TCP provides a whole range of benefits that make Internet communication as easy as pie.

Read more »

This post is part of a series:

  1. Introduction
  2. Protocols
  3. Internet Protocol
  4. User Datagram Protocol
  5. Transmission Control Protocol
  6. Domain Name System

Hello, transport layer! The User Datagram Protocol (UDP) is a simple, no frills protocol that plays an important, but sometimes neglected, role on the Internet. UDP is preferred when its main rival, TCP, is too heavyweight.

It’s our first protocol on the transport layer, so let’s begin by reviewing that.

The transport layer

Recall our four layer model. The link layer handles communication between physically connected machines. The internet layer handles communication across network boundaries. Both examples of good, honest work.

Read more »

This post is part of a series:

  1. Introduction
  2. Protocols
  3. Internet Protocol
  4. User Datagram Protocol
  5. Transmission Control Protocol
  6. Domain Name System

Previously we looked at the overall design of the Internet and how protocols work. Now we’re ready to get into the real core of how things work.

The Internet Protocol (IP) is the magic that makes the Internet possible. It’s responsible for routing packets across network boundaries and so enables internetwork communication.

Despite doing so much, IP is actually comparatively simple and pretty straightforward to grasp. Together with a few supporting algorithms it forms the internet layer of the Internet Protocol suite. In this post, we’ll see how IP and the internet layer work.

Read more »