Welcome!

Microsoft Cloud Authors: Janakiram MSV, Yeshim Deniz, David H Deans, Andreas Grabner, Stackify Blog

Related Topics: @DevOpsSummit, Java IoT, Microservices Expo, Microsoft Cloud, Linux Containers, Agile Computing

@DevOpsSummit: Blog Post

Time to Invest in Deployment By @Itransition | @DevOpsSummit [#DevOps]

You can’t be sure that every one of your app deployments will be smooth sailing

Why Now Is the Right Time to Invest in Deployment Automation

Isn't it great to treat your girlfriend by cooking her favorite omelet every morning? In theory, sure, but in reality, chances are most of the time you end up with darn scrambled eggs instead. Let's face it: you're a great boyfriend but a terrible cook. Believe it or not, this is quite analogous to app deployment. You can't be sure that every one of your app deployments will be smooth sailing; every now and then you will mess up a thing or two (or a dozen) along the way.

Be it a critical urge to rapidly roll back to a previous release or the inability to find the phone number of that one guy responsible for deployment, the opportunities for things to go terribly wrong are endless. As a rule, there are two reasons behind your worst nightmares coming true:

  • You're good at development but operations isn't your strong suit.
  • You're not using deployment automation.

In this article, we'll focus on the second point - deployment automation.

The automating software deployment process for .NET has pretty much become a ‘no-brainer' during the past few years. New tools have made it extremely easy to make deployments faster and less risky at costs tending to zero. Not using automatic deployment in 2014 is like not using source control; it's possible to live without it but having it in place keeps you safe while requiring such little effort. Yet, many still resist given their perception of the hassle around the creation, configuration and maintenance of automated deployment. And they‘re really missing out.

There are many reasons to start investing in deployment automation for .NET, including a drastic increase in deployment success rates and frequencies, but most important, it is good for business. Here's why:

Stable Manual Deployment Is a Utopia
Let's have a brief look at what it usually takes to deploy an ordinary application:

  1. Checking out the version of the source code that you want to deploy (e.g. the latest commit of the /Release_01 branch);
  2. Building solution with appropriate settings applied;
  3. Transforming configuration appropriately;
  4. Publishing/packaging new version;
  5. Stopping the application/tuning load balancer so that users don't hit the app in the middle of deployment;
  6. Backing up the database;
  7. Updating the database structure/data;
  8. Removing old files (but keeping some, e.g. /Uploads folder);
  9. Copying new version to production server;
  10. Setting appropriate ACL permissions/other environment settings;
  11. Deploying dependencies recursively;
  12. Starting the application;
  13. Executing health-checks.

That's only the basic list; of course, every application is unique and has a slightly different process (so your app may have additional steps or not require some of the aforementioned ones, but most deployments are similar).

All those steps may seem easy enough to perform manually without anything going wrong. Well, day-to-day experience says that deployments always go wrong from time to time if executed manually, mainly due to our nature. Humans (particularly creative people like developers) are not very good at performing routine repetitive tasks; that's why we have computers. Here are a few examples of some of the most avoidable manual deployment errors I've seen:

  • Checking out the version of the source code that you want to deploy:
  • Ever had /Dev branch deployed to Production environment just because the guy who executed deployment was sure he switched to /Dev branch when, in actuality, he didn't?
  • Or even worse: getting /Production branch deployed with local intermediate changes never checked in the source control (it's so easy to forget about your local changes when you are to deploy a hotfix). So no one actually understands why the application misbehaves (I've seen people decompiling production .dll with reflector to understand what is in there, because production code is different than any version in the repository).
  • Building solution with appropriate setting applied:
  • It's so easy to forget to switch Visual Studio to Release configuration before you build the source code. And it's so sad to find out that your app is too slow in production because of DEBUG compilation.
  • Transforming configuration appropriately:
  • There's not much joy in discovering that your production application uses a development database after a new release when "data loss" is reported by end users (somebody forgot to replace connection string in web.config). In general, manual configuration transformation is a bad idea, because usually it is not versioned (meaning developers have to figure out how production configuration files differ from the dev version and "merge" them manually every time. As a result nobody is actually sure what the production configuration is and when/why it was changed); "What's the requestTimeOut in production? - hmm, I see it's 300 seconds now, but it was around 100 last week - who changed it?"
  • Backing up the database:
  • Discovering you forgot to back up the production database just at the moment your migration script fails corrupting the data.

You get the idea. I have no doubt you've encountered some of the aforementioned errors and can easily add a ton of others. The key problem with these errors is the fact that it's very easy to make any of them but very hard to get to the bottom of them. As a rule, it takes a lot of effort and nervous hours to detect and fix them.

Therefore, you are forced to have either a deployment document (checklist) or a special "deployment" guy on your team (or both). Each of these approaches has major drawbacks:

  • Deployment checklists are often outdated (developers are generally bad in maintaining documentation - and they are bad for a reason; maintaining docs is boring). Moreover, new team members still need to undergo deployment training when they join the project (and it takes time).
  • Your team's bus factor is 1. No new version/hotfix can be deployed if your "deployment" guy is on vacation.

These issues will not occur if deployments are done automatically, because computers are good at repetitive tasks (humans are not).

Time Is Money: Gain Both
If you'd rather have a million dollars straight away than a penny doubled every day for one month you should revisit your math, because the latter would result in you becoming over $10M richer. The story is exactly the same when investing in deployment automation. In addition to streamlining release operations, you're gaining profit and saving resources; in other words, you're increasing ROI.

In my experience, carefully going through a deployment process manually takes at least an hour for an average developer for a small project. In an agile environment, you usually want to have frequent deployments to QA/UAT platforms, so features are delivered and validated quickly (i.e., have 3-4 QA deployments per week [meaning manual deployment costs you at least 12-16 hours per month]). On the other hand, configuring automated deployment for a simple project rarely takes more than 16 hours, while deployment itself would then be just a click away. It truly is as simple as that; automation wins even with a tight time frame. Now add up time needed to train new developers to do the deployment plus time spent to troubleshoot deployment errors. It turns out that you can save about 25-40 hours per month with automation, which translates to about $500-800.

Another important aspect is the fact that overall team performance increases, because the QA team does not need developers to be distracted from new features when QA needs a new build to be delivered for validation which; this, in turn, means greater flexibility.

Take a look at this graph from McConnell's "Software project survival guide":

The longer it takes from introducing an error to its detection, the more time (and money) it takes to fix it. Being able to deploy without a developer's involvement means much more frequent deployments, which means much quicker error detection (i.e. allows your team move even faster!).

It's also about making errors less risky, which again means higher deployment frequency. And higher frequency entails faster feedback from testers and end users.

But there's more. If done intelligently, deployment automation also provides for automated reporting into the process, which results in zero efforts and money put into complying with audit requirements, and a significant unlikelihood of audit failure.

Sound too good to be true? Here's a summary of what our team achieved in terms of ROI when we introduced deployment automation in one of our .NET projects:

Overall efforts

90 man-months

Duration

20 months

 

Manual Deployment

Automated Deployment

Deployment time

2 man-hours/deployment

16 man-hours for one-time implementation

Deployment frequency

Twice a week

Once every day

Deployment error rate

10%

2%

Deployment cost

$16h/month

16h (one-time)

Overall benefits

 

$6,400 (320 man-hours) saved

200% increase in deployment frequency

5x decrease in deployment errors

 

And that's just a simple case. For complex projects/projects with high deployment frequencies, teams can save more than a thousand of hours per year.

New Opportunities Made Possible By Deployment Automation
I am a strong advocate of deployment automation for two main reasons:

  • It saves developers from routine error-prone tasks (which saves money).
  • It opens up several new opportunities that can make a great difference to your project's overall success.

I personally think the second reason is the most important for business, because of the following:

  • Integration tests as part of your daily workflow:

Everybody knows it is cost-effective to automate regression checks. Nowadays, we have plenty of cool tools to help implement integration tests. A good suite of UI regression tests is crucial for long-running projects' sustainable development; otherwise, in a year or two, you get to a point when you can't add new features because you are in a constant rush fixing the old ones. Automatic deployment is required in order to run these tests frequently and in an automated fashion. I recommend running them throughout the day (ideally - for every check in) - this saves money and helps you keep up with the schedule as you detect errors in under an hour from introducing them (see graph above).

  • Provide visibility with nightly builds:

Everybody wants visibility in agile development. The sooner you get something done and give it to product owners/target users, the sooner you understand what they actually need from the software (so you eliminate "you built exactly what I asked you, but it is not what I need" situation). A great way to provide visibility at no cost is to set up a nightly build, which deploys the current development version to a test environment just for reference. That way, everybody who is interested (stakeholders, managers, beta users, etc.) can see what has been built on a daily basis.

  • DevOps:

If you want your team to get into the DevOps world, be ready to invest in deployment automation. Developers tend to not like ops tasks, but they love automating stuff (that's why we automate email replies and program our coffee maker to run every morning). So a boring task to configure a new UAT platform becomes a challenging, exciting thing when you want to automate it.

  • Continuous deployment:

Continuous deployment, where every change that passes automated testing is deployed to production automatically, has been gaining traction over the last few years with most major tech companies adopting it (WordPress, Google, Facebook, Amazon).

Standard workflow with automated acceptance (integration tests) employed.

The bottom line is there is no excuse these days to not to do automatic deployment on .NET web projects. Technology is mature and easy to use, it saves time and money, it eliminates hard-to-troubleshoot errors because the process is reproducible and versioned, and it allows your team to be more flexible and move significantly faster.

More Stories By Ivan Antsipau

Ivan Antsipau is a senior .NET developer at Itransition specializing in architecting and implementation of business-specific web applications. With a specialist degree in Radiophysics and Computer Science, a knack for team leading, and years of hands-on programming experience under his belt, he sees the key to sustainable and accelerated delivery of software projects in elimination of stressful manual efforts with the help of continuous integration and automated testing.

Comments (0)

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


@ThingsExpo Stories
Nordstrom is transforming the way that they do business and the cloud is the key to enabling speed and hyper personalized customer experiences. In his session at 21st Cloud Expo, Ken Schow, VP of Engineering at Nordstrom, discussed some of the key learnings and common pitfalls of large enterprises moving to the cloud. This includes strategies around choosing a cloud provider(s), architecture, and lessons learned. In addition, he covered some of the best practices for structured team migration an...
Recently, REAN Cloud built a digital concierge for a North Carolina hospital that had observed that most patient call button questions were repetitive. In addition, the paper-based process used to measure patient health metrics was laborious, not in real-time and sometimes error-prone. In their session at 21st Cloud Expo, Sean Finnerty, Executive Director, Practice Lead, Health Care & Life Science at REAN Cloud, and Dr. S.P.T. Krishnan, Principal Architect at REAN Cloud, discussed how they built...
In his session at 21st Cloud Expo, Raju Shreewastava, founder of Big Data Trunk, provided a fun and simple way to introduce Machine Leaning to anyone and everyone. He solved a machine learning problem and demonstrated an easy way to be able to do machine learning without even coding. Raju Shreewastava is the founder of Big Data Trunk (www.BigDataTrunk.com), a Big Data Training and consulting firm with offices in the United States. He previously led the data warehouse/business intelligence and B...
In his Opening Keynote at 21st Cloud Expo, John Considine, General Manager of IBM Cloud Infrastructure, led attendees through the exciting evolution of the cloud. He looked at this major disruption from the perspective of technology, business models, and what this means for enterprises of all sizes. John Considine is General Manager of Cloud Infrastructure Services at IBM. In that role he is responsible for leading IBM’s public cloud infrastructure including strategy, development, and offering m...
With tough new regulations coming to Europe on data privacy in May 2018, Calligo will explain why in reality the effect is global and transforms how you consider critical data. EU GDPR fundamentally rewrites the rules for cloud, Big Data and IoT. In his session at 21st Cloud Expo, Adam Ryan, Vice President and General Manager EMEA at Calligo, examined the regulations and provided insight on how it affects technology, challenges the established rules and will usher in new levels of diligence arou...
The 22nd International Cloud Expo | 1st DXWorld Expo has announced that its Call for Papers is open. Cloud Expo | DXWorld Expo, to be held June 5-7, 2018, at the Javits Center in New York, NY, brings together Cloud Computing, Digital Transformation, Big Data, Internet of Things, DevOps, Machine Learning and WebRTC to one location. With cloud computing driving a higher percentage of enterprise IT budgets every year, it becomes increasingly important to plant your flag in this fast-expanding busin...
Smart cities have the potential to change our lives at so many levels for citizens: less pollution, reduced parking obstacles, better health, education and more energy savings. Real-time data streaming and the Internet of Things (IoT) possess the power to turn this vision into a reality. However, most organizations today are building their data infrastructure to focus solely on addressing immediate business needs vs. a platform capable of quickly adapting emerging technologies to address future ...
No hype cycles or predictions of a gazillion things here. IoT is here. You get it. You know your business and have great ideas for a business transformation strategy. What comes next? Time to make it happen. In his session at @ThingsExpo, Jay Mason, an Associate Partner of Analytics, IoT & Cybersecurity at M&S Consulting, presented a step-by-step plan to develop your technology implementation strategy. He also discussed the evaluation of communication standards and IoT messaging protocols, data...
22nd International Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, and co-located with the 1st DXWorld Expo will feature technical sessions from a rock star conference faculty and the leading industry players in the world. Cloud computing is now being embraced by a majority of enterprises of all sizes. Yesterday's debate about public vs. private has transformed into the reality of hybrid cloud: a recent survey shows that 74% of enterprises have a hybrid cloud ...
22nd International Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, and co-located with the 1st DXWorld Expo will feature technical sessions from a rock star conference faculty and the leading industry players in the world. Cloud computing is now being embraced by a majority of enterprises of all sizes. Yesterday's debate about public vs. private has transformed into the reality of hybrid cloud: a recent survey shows that 74% of enterprises have a hybrid cloud ...
DevOps at Cloud Expo – being held June 5-7, 2018, at the Javits Center in New York, NY – announces that its Call for Papers is open. Born out of proven success in agile development, cloud computing, and process automation, DevOps is a macro trend you cannot afford to miss. From showcase success stories from early adopters and web-scale businesses, DevOps is expanding to organizations of all sizes, including the world's largest enterprises – and delivering real results. Among the proven benefits,...
@DevOpsSummit at Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, is co-located with 22nd Cloud Expo | 1st DXWorld Expo and will feature technical sessions from a rock star conference faculty and the leading industry players in the world. The widespread success of cloud computing is driving the DevOps revolution in enterprise IT. Now as never before, development teams must communicate and collaborate in a dynamic, 24/7/365 environment. There is no time to wait...
Cloud Expo | DXWorld Expo have announced the conference tracks for Cloud Expo 2018. Cloud Expo will be held June 5-7, 2018, at the Javits Center in New York City, and November 6-8, 2018, at the Santa Clara Convention Center, Santa Clara, CA. Digital Transformation (DX) is a major focus with the introduction of DX Expo within the program. Successful transformation requires a laser focus on being data-driven and on using all the tools available that enable transformation if they plan to survive ov...
SYS-CON Events announced today that T-Mobile exhibited at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. As America's Un-carrier, T-Mobile US, Inc., is redefining the way consumers and businesses buy wireless services through leading product and service innovation. The Company's advanced nationwide 4G LTE network delivers outstanding wireless experiences to 67.4 million customers who are unwilling to compromise on qua...
SYS-CON Events announced today that Cedexis will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Cedexis is the leader in data-driven enterprise global traffic management. Whether optimizing traffic through datacenters, clouds, CDNs, or any combination, Cedexis solutions drive quality and cost-effectiveness. For more information, please visit https://www.cedexis.com.
SYS-CON Events announced today that Google Cloud has been named “Keynote Sponsor” of SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Companies come to Google Cloud to transform their businesses. Google Cloud’s comprehensive portfolio – from infrastructure to apps to devices – helps enterprises innovate faster, scale smarter, stay secure, and do more with data than ever before.
SYS-CON Events announced today that Vivint to exhibit at SYS-CON's 21st Cloud Expo, which will take place on October 31 through November 2nd 2017 at the Santa Clara Convention Center in Santa Clara, California. As a leading smart home technology provider, Vivint offers home security, energy management, home automation, local cloud storage, and high-speed Internet solutions to more than one million customers throughout the United States and Canada. The end result is a smart home solution that sav...
SYS-CON Events announced today that Opsani will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Opsani is the leading provider of deployment automation systems for running and scaling traditional enterprise applications on container infrastructure.
SYS-CON Events announced today that Nirmata will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Nirmata provides a comprehensive platform, for deploying, operating, and optimizing containerized applications across clouds, powered by Kubernetes. Nirmata empowers enterprise DevOps teams by fully automating the complex operations and management of application containers and its underlying ...
SYS-CON Events announced today that Opsani to exhibit at SYS-CON's 21st Cloud Expo, which will take place on October 31 through November 2nd 2017 at the Santa Clara Convention Center in Santa Clara, California. Opsani is creating the next generation of automated continuous deployment tools designed specifically for containers. How is continuous deployment different from continuous integration and continuous delivery? CI/CD tools provide build and test. Continuous Deployment is the means by which...