In 2021 and 2022, a significant wave of engineering talent left companies, and we're still grappling with the implications for engineering leaders. The causes are well-documented, but the aftermath requires a more nuanced understanding.

Data shows that software engineering salaries grew by 15-25% year over year in many markets during 2021-2022, driven by remote work and demand from venture-funded companies. Engineers who stayed in one company for more than 18 months without renegotiating often found themselves significantly underpaid. The logical response was to leave and seek better opportunities.

When experienced engineers depart, they take institutional knowledge with them. Effective knowledge preservation involves more than just documentation; it requires continuous practices that transfer knowledge before attrition, such as pair programming, architecture decision records, and mandatory code review.

For instance, I recall a situation where a team of five engineers was suddenly reduced to two due to departures. The remaining engineers were tasked with maintaining a complex system built using a combination of Java, Apache Kafka, and MongoDB. To mitigate the knowledge loss, we implemented a knowledge-sharing program using tools like Confluence and Bitbucket. We also encouraged the engineers to document their decisions and design choices using architecture decision records. This helped to preserve some of the institutional knowledge and made it easier for new engineers to onboard.

In terms of compensation, companies like Stripe and GitLab have been known to offer competitive salaries and benefits to attract and retain top talent. However, other factors such as autonomy over technical decisions, visibility into company strategy, and investment in engineers' growth also play a crucial role in driving retention. For example, a survey by Glassdoor found that 60% of engineers consider opportunities for career growth and professional development when evaluating job offers. Engineering leaders who prioritize these aspects are more likely to retain their talent.

Competitive compensation is essential, but it's not enough to retain talent. Other factors, like autonomy over technical decisions, visibility into company strategy, investment in engineers' growth, and a team culture where engineers feel respected, play a crucial role in driving retention, particularly for senior engineers with more market options.

Companies that aggressively hired in 2021-2022 and then laid off in 2022-2023 face a significant cultural challenge. Employees who survived layoffs know that it can happen to them, shifting the implicit social contract between employer and employee. Engineering leaders who acknowledge this reality and invest in rebuilding trust are more likely to retain their talent than those who try to revert to pre-disruption norms.