Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!
We spend hours on Instagram and YouTube and waste money on coffee and fast food, but wonât spend 30 minutes a day learning skills to boost our careers.
Master in DevOps, SRE, DevSecOps & MLOps!
Learn from Guru Rajesh Kumar and double your salary in just one year.
Source:-techbeacon.com
So youâve adopted agile. Youâre holding your stand-ups, scoring your stories, doing the ceremonies the experts recommend. Youâre even beginning to see the value of the agile process. Youâre showing development progress in biweekly increments, including user feedback on a continuous basis, and everyoneâs excited!
But something feels off. It was great to start, but now your velocity is erratic. The defect list keeps growing. Testing takes longer and longer all the time. âHow can this be?â you wonder. Youâre doing all the right agile development things.
Youâre not crazy. Youâre suffering from a common malady I call âagile insufficiency.â The truth is, agile on its own doesnât deliver ROI. When you improve your development process without improving deployment as well, you eventually, inevitably, face these issues.
While this comes as a surprise to many organizations, the writers of the Agile Manifesto knew it well. Thatâs why they included lines such as âDeliver working software frequently,â and âWorking software is the primary measure of progressâ and âSponsors, developers, and users should be able to maintain a constant pace indefinitely.â They understood that software is not done in any meaningful way until itâs deployed and in the hands of customers.
Thatâs where DevOps comes in. DevOps is all about automating and improving your âvalue streamââyour process for building, constructing, and flowing features from development into production. It unlocks hidden capacity in your organization, allowing you to go fast forever without working overtime, nights, and weekends. Itâs agileâs indispensable partner. Iâd even argue that you canât get ROI from agile without it.
The question is not whether to do DevOps, but how to get started. I could write a book on that topic (and many have), but the basic principles can be briefly summarized. Here they are.
[ Continuous delivery and release automation (CDRA) demands speed and quality. Find out how in TechBeacon’s guide to CDRA. Plus: Get the Forrester Wave on CDRA. ]
1. Kill your manuals
I’m not talking about your instruction manuals, but your manual processes, which are the most common sources of error and delay. Survey your software pipeline and train yourself to watch for the word âmanual.â Manual testing. Manual deployment. Manual handoffs. Any activities where teams communicate through tickets. Those are tell-tale signs of waste and good candidates for automation.
2. Find your bottlenecks
Implement instrumentation throughout your pipeline to see where code is being held up, then focus on eliminating choke points. Nothing can move through the pipeline faster than the speed at which it can go through the slowest parts. Improvements anywhere else in the pipeline will only make the bottleneck worse, since they just pile up more tasks at the choke point. The only way to make progress is to fix your biggest hold-ups.
Once youâve automated the slowest parts of your pipeline, something else will be the slowest, and it will be time to tackle that. Youâre always getting better, but there will always be room for improvement. Itâs a never-ending process. Embrace it.
[ Learn the secrets of successful DevOps initiatives in TechBeaconâs Guide. Plus: Get the Optimizing DevOps Initiatives: Both Sides of the DevOps Divide report ]
3. Automate your tests
This is a key enabler for really effective agile. Iâve heard it described as the gold standard, but not absolutely necessary. Wrong. Automated testing is absolutely necessary. Itâs what allows you to go fast forever. People like to say they do test-driven development (TDD), but often they just mean writing the test before the code. Real TDD is automated. And effective TDD is done right now. People talk about going back to write tests later. It never happens.
If youâre going to do it (and you should), do it now. Donât just automate UI tests, but integration, unit, acceptance. Yes, it takes longer to write a test on top of feature code, but it doesnât slow you down in the long run. In fact, an automated regression suite helps you achieve a constant and indefinite pace, as the Agile Manifesto envisions. Trying to do agile with manual testing is a recipe for failure. Commit to automation with everything you have and protect it at all costs.
4. Build in quality
This means shifting quality control to the start of the process and baking it in throughout. Why accept a story and count the points only to create a defect? Why not just fix the problem and accept the story defect-free? It doesnât change the amount of work you have to do. When you account for rework, it actually costs more to do it later.
Focus on improving your processesâboth the agile process, where you focus on the flow of stories, and your deployment process, where you focus on getting the software to end users. Donât fall back into waterfall habits. Worry less about making your commitments than about making work flow smoothly and consistently through your pipeline.
To that end, establish tight feedback loops with QA/QE and customers. Test within your sprint, and only accept defect-free stories. Iâve seen too many organizations pressure teams to meet every sprint commitment, only to discover in the end a bunch of defects that push their release date out further.
5. Automate your pipeline
There are two parts to this equation. The first is continuous integration (CI). That means replacing all the manual processes associated with putting source code together: building, integrating and creating a deployable artifact that you can deploy in any environment. Old-school shops may do integration once a week. They have one big integration day when everyone puts code together and works out merge conflicts, and then they kick it over to testing and go off to build the next set of features.
As integration becomes more painful, they push it off even further. Integration every week becomes every two weeks, and then even more. The longer the two code branches are apart, the more risky and costly integration becomes. CI solves this problem by testing integrated code with every change. Short-lived branches are reviewed and integrated daily. The automated process runs every time thereâs a source code commit, performing security scans and static code analysis, ensuring developers are adding code that moves the project forward.
Dev shops often have a CI solution in-house, which is good. Where they can fall short is continuous delivery (CD), a process that automatically takes output from the CI, combines it with secrets (passwords and other items you shouldnât store in source code) and puts together in an environment.
The key is to use the same automated process whenever a package goes to any environment, whether itâs dev, QA, stage or prod. A human should never go through and click configuration steps, or manually copy software into an environment, or manually stand up servers. Every CD deployment should be automated the same way, so every time you run the process it’s like a dress rehearsal for live deployment.
To make this work you must get buy-in from ops. Dev teams sometimes go all-in on CI and CD, while ops continues with manual processes. This results in larger batch sizes, greater risk of error, and higher rates of failure as features stack up for deployment. Donât let this happen to you. Everyone from dev and ops needs to be on board with automation, and the same process needs to be used for all deployments to all environments.
6. Choose metrics that drive the right behavior
Any time you establish a metric, people will try to game it. And if you measure the wrong thing, youâll get the wrong results. Both are common problems in software development. Project managers try to measure progress with metrics that drive the wrong behaviors. Percentage done, lines of code, number of defects, number of storiesâthese metrics can be easily gamed to give the appearance of progress, but they donât generate business value.
Choose metrics directly related to your business goal: getting features into the hands of customers. It really is that simple. How long does it take to get something from idea, to end user? To measure that, we propose these three metrics:
Lead timeâTime from first line of code to deployed to production. Many businesses would be shocked to find out that the actual lead time can be six months, eight months, even a year. The more you reduce that lead timeâif you can bring it down to months or weeks or hoursâthe better for your business. The metric tells you a lotânot just about how fast you can write code, but how fast you can get out in the world.
Deployment frequencyâHow frequently do you deploy? Once a quarter? Twice a year? Or 11 times a minute? More frequent deployments are a good sign that your entire DevOps pipeline is becoming faster and more reliable. The metric also encourages smaller batch sizes, which tend to produce more reliable code.
Mean time to recoverâFailures happen. They happen with waterfall, they happen with agile, they happen on-premises, and they happen in the cloud. We have to be able to both detect them and recover from them quickly. DevOps is about operating safely at speed. Sometimes youâll miss an edge case, or a server will go down. The questions are, How fast can you recover, and how do you do it? Rollback? Fix-forward? A manual legacy release process might take a weekend to deploy, and all too often you find out on Sunday that something went wrong and you need to roll back. But if you create blue and green deployment environments, and deploy live by switching between the two, you can switch back if thereâs a problem and recover in about a minute. Big difference.
Start small, think big
If this all sounds like a lot, donât worry. Thereâs no harm starting small with DevOps. In fact, I recommend it. Groups Iâve worked with that commit to improving over time have been more successful than those that try to do everything at once in a big bang. Agile alone may not be sufficient for developers to go fast forever, but it takes you a long way, and you can get the rest of the way over time.
Just focus on the simplest possible task in front of you and making each commit a bit better. As long as you have all the stakeholders on board, every bit of progress is a net win. Small wins attract support for bigger ones, and pretty soon youâll have created a virtuous cycle that generates astronomical returns.