Local development is an XY problem

An XY Problem is a communication problem where a question is asked about an end user’s attempted solution (Y) rather than the root problem itself (X).

A common example of this in building serverless apps is that of local development. Developers new to serverless often ask me “how do I run this locally on my machine?” and my typical reply of “you don’t” causes temporary confusion until I further explain to them my reasons for preferring a cloud sandbox approach to dev environments.

Whether you agree with me or not on this isn’t really important, the key point is that local development isn’t in itself the goal. Rather, local development has traditionally been the only vehicle through which the real developer goals of a fast feedback loop and the ability for individual developers to work in an isolated environment can be effectively realised. (Another minor benefit is being able to work without a network connection, but this carries much less importance with most cloud developers today).

“Local” is just one implementation mechanism for delivering on these developer goals, albeit the predominant one historically. Some tools such as the Architect framework take an opinionated pro-local stance whereas others such as Serverless Cloud take the cloud sandbox approach where developers work within their own production-fidelity cloud environment. Both tools are focused on enabling individual developers to iterate fast independently, they just implement this differently.

When we’ve being practising something like local development for so long that it’s become taken for granted as something all devs should do, it helps to occasionally take a step back and ask why we’re doing it this way.

Join daily email list

I publish short emails like this on building software with serverless on a daily-ish basis. They’re casual, easy to digest, and sometimes thought-provoking. If daily is too much, you can also join my less frequent newsletter to get updates on new longer-form articles.

    View Emails Archive

    ☎️ Serverless Clarity Call

    Need quick guidance on a specific issue on your AWS serverless project? Or just wondering where to start with serverless?

    Book a call and ask me anything.

    Learn more >>

    🛫 Serverless Launchpad

    Ready to start building your new AWS serverless project but need help with getting everything setup?

    The Serverless Launchpad is a done-for-you DevOps service installed in under a week. You get a leading-practice multi-account AWS environment, a scaffolded codebase and architecture including the common AWS serverless services, isolated cloud environments for individual developers, automated delivery pipelines right through to production and much more. Everything is IaC, extensively documented and handed over to your developers.

    Learn more >>