We all need a Holiday Destination Finder
Tiptoeing Through the Asynch Door with the CompletionStage Interface JSE17
When it comes to holidays, I’m as spontaneous as they come. I enjoy not planning and picking the best option available just before or even while traveling.
So I needed a holiday… and a reason to explore Java’s async magic.
We’ll get to this Holiday Finder but first let’s get the theory out of the way, shall we?
Diving Right In
Considering two API calls A & B, API A is called first, and then API B. This is what synchronous code does: it waits before executing the next task and things run in order. However, could the thread blocked on the API response be doing some other work instead?
Welcome to the Code Aviary: Where Ducks Debug and Canaries Die
Your survival guide to feathered philosophies in software development
Rubber Duck Debugging
Alright, we’re starting easy and light for this one.
It was popularised by the Pragmatic Programmer written by Andrew Hunt and David Thomas (an alumnus of Imperial College London). The idea is rather simple: instead of spending hours trying to debug something obscure, explain the code line-by-line to an inanimate object - a rubber duck named Chucky maybe? - to help you work out what the problem is.
The Poor Man's Load Balancer
Domain Name System: traffic distribution on a budget
It’s not magic
What happens when you type leane.dev
in
your browser?
As a regular reader of this blog, I am allowing myself to take your everyday example.
You want to access the server hosting this blog, but how do you reach it? On the Internet, routing is done by finding the path to a given Internet Protocol - IP. Thing is: you don’t know my IP, not directly. It’s easier to remember the hostname: leane.dev. Yet, the browser manages to display the blog to you.