Why Synthetic Monitoring and End-to-End Testing Belong Together
March 21, 2023

Hannes Lenke
Checkly

Share this

Synthetic monitoring is crucial to deploy code with confidence as catching bugs with E2E tests on staging is becoming increasingly difficult. It isn't trivial to provide realistic staging systems, especially because today's apps are intertwined with many third-party APIs.

That's why nowadays, the low-hanging fruit is to set up checks that constantly monitor your production environment from an end-user perspective. This allows you to quickly find and fix issues on production before they become a problem for your customers. However, you need both testing in pre-production and monitoring on production.

Whether e-commerce shops or complex banking setups, systems are becoming increasingly intertwined and also distributed. They do not only rely on internal services but also on many external APIs such as payment APIs. It's nearly impossible to spin up production-like staging systems for these architectures. However, developers are, for many reasons, tasked to ship small pieces of new software numerous times a day. And this requires automation that ensures changes do not introduce bugs and break crucial flows while still delivering at speed and scale.

So on one side, we have complex systems that are nearly impossible to test fully in pre-production, and on the other, we have an increasing need for faster software delivery. These two things are like two trains on the same track heading for a collision. Thankfully, synthetic monitoring is here for the rescue!

But what is testing, and what is synthetic monitoring?

Let's look at synthetic monitoring and testing and what both could learn from each other. I'm sure ChatGPT can help us to define both terms:

Synthetic Monitoring

Synthetic monitoring tests and examines websites, applications, or services to ensure all components, including APIs, function as expected. It helps identify potential issues before they become a problem for the user or connected systems. It can be done from worldwide distributed remote locations. In simple terms, synthetic monitoring is having automated scripts checking your assets constantly to see if they are working correctly.

E2E testing

E2E testing helps to ensure the complete flow of an application or website works as expected before it gets deployed to production. It involves running tests to ensure all components work correctly from start to finish, as a real user would. In other words, it's like having an automated virtual tester check your web app to see if it works how it should.

Synthetics + Testing

In theory, synthetic monitoring and E2E testing are quite similar. While monitoring is meant to test your app on production constantly, E2E testing is intended to catch bugs before you deploy. The main difference in the past was that quality assurance (QA) teams performed testing while monitoring was the responsibility of operations (OPS), so the responsibility was split between two siloed teams. Not anymore!

Testing matured during the last decade from proprietary algorithms to open-source-based code hosted in your repository next to your application code. Today, cross-functional DevOps teams continuously run automated E2E tests in their CI/CD pipeline instead of isolated QA teams testing new versions of your app for three months before release.

Synthetic monitoring is also evolving similarly. It follows the transition E2E testing has already made: From proprietary scripts living in closed monitoring platforms to open-source-based scripts embedded in your repository. Monitoring is shifting left, as testing did, and is becoming integral to your developer's pipeline. The industry should encourage and enable developers to use the same scripts for pre-production tests and production monitoring. Doing so will blur the lines between E2E testing and synthetic monitoring.

So what does modern synthetic monitoring look like? Monitoring as code (MaC) is the next evolution of synthetic monitoring. To be successful in a MaC approach, we need to look at three essential pillars that make up the MaC concept: code, test, and deploy:

1. Code: Automated tests are defined as code and live in a repository, often close to your application code. When I write code, I mean code, not just configuration files saved in a repository. With that approach, MaC enables flexibility and programmability, allowing you to test your backend and UI by supporting complex API and browser checks.

2. Test: Synthetic monitoring was traditionally meant to run on production only. Now, checks as code enable us to run all or some of these checks locally and in a CI/CD flow to be tested on staging before a new version gets deployed. Monitoring is becoming testing, and testing is becoming monitoring, blurring the lines between the two.

3. Deploy: The main difference between testing and monitoring is scheduling. MaC enables us to schedule our tests, executing these constantly, 24/7, in distributed remote locations worldwide. In other words, your tests are deployable. In addition, deploying your tests via your CI/CD process allows monitors to be updated with application code changes.

Synthetic monitoring has been evolving quickly during the last months. We see many exciting approaches to enable developers to ensure that their apps are reliable and resilient. Monitoring as code is the only logical next step, as it has many advantages and enables you to reuse your tests.

Hannes Lenke is CEO and Co-Founder of Checkly
Share this

The Latest

April 25, 2024

The use of hybrid multicloud models is forecasted to double over the next one to three years as IT decision makers are facing new pressures to modernize IT infrastructures because of drivers like AI, security, and sustainability, according to the Enterprise Cloud Index (ECI) report from Nutanix ...

April 24, 2024

Over the last 20 years Digital Employee Experience has become a necessity for companies committed to digital transformation and improving IT experiences. In fact, by 2025, more than 50% of IT organizations will use digital employee experience to prioritize and measure digital initiative success ...

April 23, 2024

While most companies are now deploying cloud-based technologies, the 2024 Secure Cloud Networking Field Report from Aviatrix found that there is a silent struggle to maximize value from those investments. Many of the challenges organizations have faced over the past several years have evolved, but continue today ...

April 22, 2024

In our latest research, Cisco's The App Attention Index 2023: Beware the Application Generation, 62% of consumers report their expectations for digital experiences are far higher than they were two years ago, and 64% state they are less forgiving of poor digital services than they were just 12 months ago ...

April 19, 2024

In MEAN TIME TO INSIGHT Episode 5, Shamus McGillicuddy, VP of Research, Network Infrastructure and Operations, at EMA discusses the network source of truth ...

April 18, 2024

A vast majority (89%) of organizations have rapidly expanded their technology in the past few years and three quarters (76%) say it's brought with it increased "chaos" that they have to manage, according to Situation Report 2024: Managing Technology Chaos from Software AG ...

April 17, 2024

In 2024 the number one challenge facing IT teams is a lack of skilled workers, and many are turning to automation as an answer, according to IT Trends: 2024 Industry Report ...

April 16, 2024

Organizations are continuing to embrace multicloud environments and cloud-native architectures to enable rapid transformation and deliver secure innovation. However, despite the speed, scale, and agility enabled by these modern cloud ecosystems, organizations are struggling to manage the explosion of data they create, according to The state of observability 2024: Overcoming complexity through AI-driven analytics and automation strategies, a report from Dynatrace ...

April 15, 2024

Organizations recognize the value of observability, but only 10% of them are actually practicing full observability of their applications and infrastructure. This is among the key findings from the recently completed Logz.io 2024 Observability Pulse Survey and Report ...

April 11, 2024

Businesses must adopt a comprehensive Internet Performance Monitoring (IPM) strategy, says Enterprise Management Associates (EMA), a leading IT analyst research firm. This strategy is crucial to bridge the significant observability gap within today's complex IT infrastructures. The recommendation is particularly timely, given that 99% of enterprises are expanding their use of the Internet as a primary connectivity conduit while facing challenges due to the inefficiency of multiple, disjointed monitoring tools, according to Modern Enterprises Must Boost Observability with Internet Performance Monitoring, a new report from EMA and Catchpoint ...