<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mitchell Shelton on Medium]]></title>
        <description><![CDATA[Stories by Mitchell Shelton on Medium]]></description>
        <link>https://medium.com/@mitchellshelton97?source=rss-1eb4202a0968------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*0V0AGjBFDmsnOjLVZJOsVw@2x.jpeg</url>
            <title>Stories by Mitchell Shelton on Medium</title>
            <link>https://medium.com/@mitchellshelton97?source=rss-1eb4202a0968------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 20:19:58 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mitchellshelton97/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Key Lessons Learnt From Scaling a Development Environment]]></title>
            <link>https://medium.com/@mitchellshelton97/key-lessons-learnt-from-scaling-a-development-environment-2c1af911c31?source=rss-1eb4202a0968------2</link>
            <guid isPermaLink="false">https://medium.com/p/2c1af911c31</guid>
            <category><![CDATA[software-architecture]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[scaling]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Mitchell Shelton]]></dc:creator>
            <pubDate>Wed, 01 Apr 2020 00:13:24 GMT</pubDate>
            <atom:updated>2020-04-01T00:13:24.731Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/proxy/0*M-4jfBlHBvMlF_FI" /><figcaption>Photo by <a href="https://unsplash.com/@technobulka?utm_source=medium&amp;utm_medium=referral">Stanislav Kondratiev</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p><em>Note: Environment and Stage are used interchangeably in this article</em></p><p>Scaling is a necessary component for the growth of any company. Scaling isn’t limited to the product or the number of employees. There is a point where it is necessary to have your development toolkit scale alongside your team as well.</p><p>I’m extremely proud to have a direct impact on the scaling at<a href="https://www.fitsense.io/"> <strong>FitSense</strong></a>. One problem I recently came across was <strong>multiple developers testing their changes</strong> in the <strong>same online development environment</strong>. This caused non-deterministic results for each developer’s tests as changes to the deployed code resulted in clashes.</p><p>Why is this a problem? because <strong>developers had to ‘tiptoe’ around each other by letting other developers know when they needed the dev environment for testing</strong>. This is <strong>not feasible for a larger team size</strong> because developers would have to wait for other developers to finish testing, which creates a <strong>massive bottleneck on development time</strong>.</p><p>This is where scaling your development toolkit is so important. No doubt many development teams will face this exact problem above. Without any thought for scaling the tool chain, development productivity will be lower than expected, ultimately causing business output and clients to suffer.</p><p>A temporary solution would be to only test changes locally, but for some applications there could be a massive overhead to set up the application to work locally for every developer. Sometimes, it may not be feasible due to different operating systems or lack of local support. Docker is a great tool for solving the above problems, as it can be used to pack your application into an environment that stays consistent for everyone. However, it can be hard to mock certain cloud resources locally, which is why testing in the cloud may be your only solution.</p><p>What we require is the ability for developers to <strong>deploy the application on demand</strong> to the cloud such that their <strong>deployed environment is isolated</strong> from all other deployed environments. In order to be able to deploy the application on demand, it is necessary to implement the infrastructure as code. This is exactly what we did at<a href="https://www.fitsense.io/"> <strong>FitSense</strong></a> using<a href="https://serverless.com/"> <strong>Serverless</strong></a>,<a href="https://aws.amazon.com/cloudformation/"> <strong>AWS CloudFormation</strong></a>,<a href="https://seed.run/"> <strong>Seed Pipelines</strong></a> and<a href="https://about.gitlab.com/"> <strong>Gitlab</strong></a>, we nicknamed it <strong>‘Popup Stacks’</strong>.</p><p>Below, I will go through some key lessons I learnt from implementing Popup Stacks.</p><h3>Ease of Use — Make it simple to use!</h3><p>It is crucial that adding a new tool to the development toolkit does not make development harder. If it becomes a hassle to use this new tool, <strong>developers simply won’t use it</strong>. The entire process must be smooth. For popup stacks, it means they need to be easy to create and destroy.</p><p>Creation could be done by checking out and creating a new git branch</p><pre>git checkout -b popup-stack<br>git push origin popup-stack</pre><p>Deletion could be done by deleting a git branch</p><pre>git push -d origin popup-stack</pre><p>Behind the scenes, the CI system would use a webhook to detect these events, which would then kick off deploying the application in an isolated environment, but to the developer it is a blackbox.</p><h3>Naming — Make resource names unique by including the stage!</h3><p>Naming should be one of the highest priority conventions to keep in mind when writing infrastructure as code. Knowing how to name resources uniquely will save you a lot of time and pain. For infrastructure, you should always <strong>include the stage in the name</strong>. This will ensure that resources you deploy for a specific environment won’t clash with existing resources for other deployed environments. You should also keep your naming conventions consistent, try not to change it once you have implemented it unless you really need to.</p><p>A simple rule of thumb:</p><pre>{resource}-{stage} is better than {resource}</pre><pre>for example: database-dev, database-prod, database-popup-stack</pre><p>Unfortunately, if you have already deployed your ‘dev’, ‘staging’ or ‘prod’ environments without including the environment in resource names, then you have a decision to make. You can either:</p><ol><li>Take down the existing resources and re-deploy them with the environment in the names</li><li>Work around them but make sure Popup Stacks use the environment in the names</li></ol><p>Be aware that option 1 can create headaches, for example, you may need to migrate your databases in prod.</p><h3>Limits — Cloud costs will go up due to increased development productivity</h3><p>Developers work on many features and with the inclusion of popup stacks your <strong>developers will become more productive</strong>, which means there will be <strong>more resources deployed</strong> to the cloud at one time. Very quickly you will begin to hit the limits of your cloud service provider. Generally, I found the limits were mostly related to the:</p><ul><li>Number of ‘x’ amount of resource that can be deployed at one time</li><li>Number of requests that can be sent at one time to the cloud service provider</li><li>Differing naming constraints imposed by the cloud service provider (For example a name can’t be too long)</li></ul><p>However, there are also business limits to consider. Be aware, that the more resources deployed means <strong>higher costs</strong>. That’s why it’s important that popup stacks <strong>don’t stay deployed</strong> <strong>forever</strong>, they should be taken down when a feature is finished. We also noticed a massive increase of build minutes usage in our CI system, which meant we had to increase our plan.</p><h3>Keep Things Simple — Don’t reuse existing resources!</h3><p>You might be tempted to reuse existing resources like a VPC or database. It will save you costs as there are less resources required to be deployed. However, it makes the whole implementation complex and <strong>humans suck at complexity</strong>. Follow the KISS principle, <strong>Keep It Simple, Stupid</strong>. Another one is Occam’s razor, which can be paraphrased to “the simplest solution is most likely the right one.”</p><p>Originally, I did attempt to reuse the dev DynamoDB database resource for every popup stack but then I ran into this perplexing problem. When a developer created a popup stack that contained broken code, the dev environment would be able to trigger the popup stacks DynamoDB streams, which would run broken code, output malformed entries into the dev DynamoDB database and then dev would fail when it read this record. This was possible because they both shared the same DynamoDB streams. In short,<strong> just</strong> <strong>keep things simple</strong>.</p><h3>Be Flexible — Don’t let new tools dictate the development workflow!</h3><p>The idea behind popup stacks is to have a completely isolated environment in the cloud to test your changes. However, developers still need to test their changes in the original dev environment.</p><p>A problem I came across was that developers were deploying to the dev environment from a different git branch. Since popup stack stage names are based on git branch names, an incompatibility arose because they were unable to deploy to a different environment from the one they were currently working on.</p><p>Therefore, it is crucial that popup stacks have the ability to deploy to a different environment no matter what environment they are currently on (although we can’t have developers deploying straight to staging or prod.) This problem was solved by allowing developers to set an environment variable that deployed to a specific stage whenever they required this functionality.</p><h3>Testing — Isolate popup stacks from dev, staging and prod environments!</h3><p>It’s important to <strong>have your own playground when testing popup stacks</strong>. If you test in the same account that contains your deployed dev environment, you may interfere with the development workflow.</p><p>It’s also extremely important that you’re confident in the <strong>ability of popup stacks to be</strong> <strong>integrated smoothly into the dev, staging and prod environments</strong>. One of the most useful tests I ran was to deploy the existing dev environment in a new account and then re-deploy over that with the popup stacks code. This helped me find countless errors and when the time came to integrate popup stacks into our development workflow, there were minimal hitches.</p><h3>Metrics</h3><p>I may write a future article detailing key metrics that changed due to the addition of popup stacks in our development workflow.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2c1af911c31" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>