Terraform plans got 6x faster because we read the news
Two or three years ago, we established a weekly meeting called Cloud News to keep us informed about industry news and trends. We rotate the duty of preparing it, so everyone is equally involved. Nowadays, the research is mostly an agent's job: it comes up with the news in a tabular format. The human part is what makes the meeting worth having. The assigned engineer sets the context, presents the highlights and provides the analysis.
In the beta of v1.17, HashiCorp introduced a Terraform command line option called -minimal-refresh. It speeds up planning by refreshing only the resources that have proposed changes. We came across it and presented it in Cloud News on September 29, discussed the feature and planned tests based on it.
Our Terraform configurations are resource-heavy, integrate different providers and power our platform, so pipeline execution times often span 10 to 30 minutes. We would have counted any savings of a minute or so as a win, since it means less compute and less idle time for engineers.
Early experiments showed much more. Our Web Application Firewall configuration went from 16 to 4 minutes (4x), and our Kubernetes configuration from 30 to 5 minutes (6x). Because the flag skips the refresh for untouched resources, it can no longer double as drift detection, so we introduced nightly drift detection that runs without it. Stability did not change, and we continue to detect drift.
This dwarfs the other improvements we've made over the years. Notably, we would not have found it through our usual tooling: a Renovate PR bumps the Terraform version, but it can't know that a new, opt-in flag is worth enabling. Someone had to read the news, understand it and decide to test it. That is exactly what the Cloud News format is for.
There is another point worth stressing. A win like this one can't be planned, because you never know which news item will pay off. What we can do is create the conditions for it. Our Cloud News meeting is a small instance of the Third Way of DevOps: continual experimentation and learning, done together. And nobody told us to do it. Making time for learning was the team's own choice.