TLDR Web Dev

TLDR WEB DEV 2024-03-01

5 sections17 entrieslinks blockcomplete parse

Parse notes

  • Subscription/account footer truncated before parsefooter_truncated

01ARTICLES & TUTORIALS

HAPPY LEAP DAY!

Software systems that don't properly account for Leap Days have a tendency to glitch or fail on February 29th. This year is no exception, with reports of failures in supermarket payment systems, airline ticketing, gas station payment terminals, smartwatches, and even a major video game. To prevent this from happening, software engineers should use framework-level date libraries wherever possible, be wary of edge cases, and not assume fixed durations for months and years.

blog.pragmaticengineer.com6 min read

HOW APPLE BUILT ICLOUD TO STORE BILLIONS OF DATABASES

Apple's iCloud and CloudKit were built using a combination of Cassandra and FoundationDB. Cassandra, which is being actively improved by Apple engineers, handles exabytes of data and millions of queries. FoundationDB powers CloudKit, Apple’s cloud backend service. It provides key features like transactional guarantees and solves scalability issues that Cassandra alone could not address. Each iCloud user gets their own database, resulting in billions of databases. This is made possible by the Record Layer's stateless architecture and resource allocation using a “record store” abstraction.

read.engineerscodex.com10 min read

INSIDE IMESSAGE EXTENSIONS — THE QUIRKY WORLD OF APPLE’S NICHE DEVELOPMENT TOOLS

Together To Do is an iMessage extension designed to replace comma-separated text messages with a checkable list. Its developer found it challenging to integrate SwiftUI into iMessage extensions as Apple doesn’t use SwiftUI by default yet. Adding to this, iMessage functionality in the iOS 17 simulator was broken, making testing difficult and necessitating workarounds with older simulators or physical devices. While the potential audience within the iMessage App Store is smaller than the regular App Store, Together To Do has achieved notable rankings and consistent organic downloads, suggesting that iMessage extensions may be a viable niche.

bit.ly12 min read

02OPINIONS & ADVICE

YOU'VE JUST INHERITED A LEGACY C++ CODEBASE, NOW WHAT?

When first starting work on a legacy C++ codebase, you should prioritize making the codebase manageable in terms of security, development experience, correctness, and performance by focusing on small, incremental changes. Aim for a passing test suite, remove dead code, enforce linters and code formatters, set up automated builds, and clearly document how to build and test the project. It’s also important to obtain buy-in from management by explaining the issues with the codebase and proposing solutions in non-technical terms.

gaultier.github.io16 min read

WHERE I’M AT ON THE WHOLE CSS-TRICKS THING

The founder of the CSS-Tricks website sold the website in March 2022 to DigitalOcean, who promptly fired the content team and stopped publishing new content. He tried to regain control of CSS-Tricks and proposed running the site himself, but DigitalOcean ultimately declined the proposal due to a lack of internal support. Today, CSS-Tricks remains in a somewhat abandoned state.

chriscoyier.net6 min read

NOTES FROM “WHY CAN’T WE MAKE SIMPLE SOFTWARE?”

It’s important to be “scale appropriate” when architecting software. Complexity multiplies with factors like supported browsers, platforms, and screen sizes. The tools that worked previously may no longer be suitable as you scale. Embrace the need to rebuild with new tools to manage the increased complexity.

blog.jim-nielsen.com3 min read

03LAUNCHES & TOOLS

NEW TO THE WEB PLATFORM IN FEBRUARY

The stable releases of Firefox 123 and Chrome 122 have updates including declarative shadow DOM, a new Storage Buckets API, and a feature that preloads resources with the 103 Early Hints HTTP code.

web.dev2 min read

PINGORA

Pingora is a Rust framework for building fast, reliable, and programmable networked systems. Cloudflare uses it to serve more than 40 million requests per second.

github.comGitHub repository

AWS LAMBDA WEB ADAPTER

AWS Lambda Web Adapter is a tool for running web applications on AWS Lambda. It allows developers to build web apps that use an HTTP API with familiar frameworks like Express.js, Laravel, Next.js, Flask, and more on AWS Lambda.

github.comGitHub repository

04MISCELLANEOUS

HOW DO COMPANIES SHIP CODE TO PRODUCTION?

The typical code deployment process for companies starts with planning and development, where developers work in sprints while product owners refine requirements as user stories. Automated systems are then used to verify that the code passes tests. The code is deployed to dev and QA environments for testing before being deployed to production.

x.com3 min read

ON GETTING PAID FOR OPEN SOURCE

Open source can be integrated into your job, but not every company offers these roles. This author's open source work began as part of their regular job, evolving into dedicated company time and side consulting gigs. Despite various funding models, including sponsorships and partnerships, they found it difficult to make a living solely from open source outside of a company.

radekmie.dev9 min read

PREVENTING SQL INJECTION ATTACKS IN NODE.JS

SQL injection can occur when user input is used in SQL queries without validation, allowing attackers to manipulate queries for malicious purposes. To prevent SQL injection attacks, developers should use query placeholders or prepared statements to ensure user input is treated as data, not code. They should also validate and sanitize user input to enforce format and character restrictions.

snyk.io10 min read